From a75a7ed0860ec4cc91f538c8222822f40229b402 Mon Sep 17 00:00:00 2001 From: Albert Astals Cid Date: Sat, 1 Mar 2014 17:01:14 +0100 Subject: [PATCH] Do not start a text generation thread if we're closing Fixes occasional crash and makes no sense either :D --- core/generator.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/generator.cpp b/core/generator.cpp index 41beb92b7..33c79936f 100644 --- a/core/generator.cpp +++ b/core/generator.cpp @@ -229,7 +229,7 @@ void Generator::generatePixmap( PixmapRequest *request ) * We create the text page for every page that is visible to the * user, so he can use the text extraction tools without a delay. */ - if ( hasFeature( TextExtraction ) && !request->page()->hasTextPage() && canGenerateTextPage() ) { + if ( hasFeature( TextExtraction ) && !request->page()->hasTextPage() && canGenerateTextPage() && !d->m_closing ) { d->mTextPageReady = false; d->textPageGenerationThread()->startGeneration( request->page() ); }