From f32f0aff4b19461677cedfcab7bd3f66689cfe03 Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Fri, 1 Dec 2017 18:50:39 +0200 Subject: MAINT-8036 Fixed Viewer freezing when overwriting existing snpshot with new one. --- indra/newview/llviewerwindow.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp index 364de1d810..28f6837679 100644 --- a/indra/newview/llviewerwindow.cpp +++ b/indra/newview/llviewerwindow.cpp @@ -4442,7 +4442,8 @@ BOOL LLViewerWindow::saveImageNumbered(LLImageFormatted *image, BOOL force_picke err = LLFile::stat( filepath, &stat_info ); i++; } - while( -1 != err ); // search until the file is not found (i.e., stat() gives an error). + while( -1 != err // Search until the file is not found (i.e., stat() gives an error). + && is_snapshot_name_loc_set); // Or stop if we are rewriting. LL_INFOS() << "Saving snapshot to " << filepath << LL_ENDL; return image->save(filepath); -- cgit v1.2.3