From ca3395ec88596572408325a7802e8e3f0f9bdbdc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Peter=20K=C3=BCmmel?= Date: Tue, 1 Mar 2011 19:39:47 +0000 Subject: [PATCH] #7163: don't delete objects which a thread needs later on git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37818 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/graphics/GraphicsLoader.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/graphics/GraphicsLoader.cpp b/src/graphics/GraphicsLoader.cpp index 3e6664651e..d37be92e65 100644 --- a/src/graphics/GraphicsLoader.cpp +++ b/src/graphics/GraphicsLoader.cpp @@ -368,7 +368,11 @@ void Loader::Impl::resetFile(FileName const & file) // signal needs to be disconnected. sc_.disconnect(); cached_item_.reset(); - Cache::get().remove(old_file); + if (status_ != Converting) { + Cache::get().remove(old_file); + } else { + //TODO remove cache item when it is not busy any more + } } status_ = cached_item_.get() ? cached_item_->status() : WaitingToLoad;