diff --git a/apps/openmw/mwworld/cellpreloader.cpp b/apps/openmw/mwworld/cellpreloader.cpp index c870369c9..60c1f9ca0 100644 --- a/apps/openmw/mwworld/cellpreloader.cpp +++ b/apps/openmw/mwworld/cellpreloader.cpp @@ -198,10 +198,11 @@ namespace MWWorld CellPreloader::~CellPreloader() { for (PreloadMap::iterator it = mPreloadCells.begin(); it != mPreloadCells.end();++it) - { it->second.mWorkItem->abort(); + + for (PreloadMap::iterator it = mPreloadCells.begin(); it != mPreloadCells.end();++it) it->second.mWorkItem->waitTillDone(); - } + mPreloadCells.clear(); }