diff options
author | Eli Linden <eli@lindenlab.com> | 2010-03-05 11:08:30 -0800 |
---|---|---|
committer | Eli Linden <eli@lindenlab.com> | 2010-03-05 11:08:30 -0800 |
commit | 5eb5602220bf65804ddccd8ce7d455a1487fbb39 (patch) | |
tree | 6c7440c82b1daeeca4d908cf9d163e882de76c65 /indra/newview/llappviewer.cpp | |
parent | 8e4aa522b2b0c71321cb90c029ca071346985b6d (diff) | |
parent | b9a96aaeb3aaf4a5e30364ddcba5af40cceb3e83 (diff) |
Merge
Diffstat (limited to 'indra/newview/llappviewer.cpp')
-rw-r--r-- | indra/newview/llappviewer.cpp | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index 6d4c90c2b9..ccd58e26fe 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -1516,7 +1516,7 @@ bool LLAppViewer::cleanup() LLAvatarIconIDCache::getInstance()->save(); llinfos << "Shutting down Threads" << llendflush; - + // Let threads finish LLTimer idleTimer; idleTimer.reset(); @@ -1530,19 +1530,26 @@ bool LLAppViewer::cleanup() pending += LLVFSThread::updateClass(0); pending += LLLFSThread::updateClass(0); F64 idle_time = idleTimer.getElapsedTimeF64(); - if (!pending || idle_time >= max_idle_time) + if(!pending) + { + break ; //done + } + else if(idle_time >= max_idle_time) { llwarns << "Quitting with pending background tasks." << llendl; break; } } - + // Delete workers first // shotdown all worker threads before deleting them in case of co-dependencies sTextureCache->shutdown(); sTextureFetch->shutdown(); sImageDecodeThread->shutdown(); + sTextureFetch->shutDownTextureCacheThread() ; + sTextureFetch->shutDownImageDecodeThread() ; + delete sTextureCache; sTextureCache = NULL; delete sTextureFetch; |