summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Productengine <adyukov@productengine.com>2010-10-27 19:23:52 +0300
committerAndrew Productengine <adyukov@productengine.com>2010-10-27 19:23:52 +0300
commitea32129f493712fd8d03d8c3454f78f89f268e61 (patch)
treed4195f661d2d759536ee21eb58694abfcd6c30aa
parent8947724baa6d595844daeee2f18c865d1886acc5 (diff)
STORM-452 FIXED Made protective fix for crash in LLAgentCamera::resetView().
I managed to reprodcuce the crash once and couldn't reproduce it any time later, so this fix is made judging from line that I found (viewer was in debug mode when it happened) in call stack after crash. Added check for gMenuHolder against NULL to prevent further crashing. There is no 100% guarantee that this fixes the crash from ticket, but it won't do any harm either.
-rw-r--r--indra/newview/llagentcamera.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/indra/newview/llagentcamera.cpp b/indra/newview/llagentcamera.cpp
index 68e408d3e4..7c953cd2dc 100644
--- a/indra/newview/llagentcamera.cpp
+++ b/indra/newview/llagentcamera.cpp
@@ -296,8 +296,11 @@ void LLAgentCamera::resetView(BOOL reset_camera, BOOL change_camera)
LLSelectMgr::getInstance()->deselectAll();
}
- // Hide all popup menus
- gMenuHolder->hideMenus();
+ if (gMenuHolder != NULL)
+ {
+ // Hide all popup menus
+ gMenuHolder->hideMenus();
+ }
}
if (change_camera && !gSavedSettings.getBOOL("FreezeTime"))