summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
authorSoap Frenzy <12368561+soapyf@users.noreply.github.com>2026-09-19 10:25:25 -0400
committerGitHub <noreply@github.com>2026-09-19 17:25:25 +0300
commit0a60806f8973c05b68cf65a5a01c41d81ff2da7b (patch)
treea6ecc3f2997f24cc74b49d02c4c01f8b4b2caa60 /indra/newview
parent95942d7abea7d39f1faa5c623486f998850eac26 (diff)
#6320 Fix crash when containing object is destroyed during inventory rename
When an in-world object is destroyed (via llDie, temp expiration, or deletion) while an item inside its Contents tab is being renamed, the viewer crashes with an Access Violation (0xC0000005) during LLMortician teardown.
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/llpanelobjectinventory.cpp25
1 files changed, 25 insertions, 0 deletions
diff --git a/indra/newview/llpanelobjectinventory.cpp b/indra/newview/llpanelobjectinventory.cpp
index 5f5c8302fe..33231e8405 100644
--- a/indra/newview/llpanelobjectinventory.cpp
+++ b/indra/newview/llpanelobjectinventory.cpp
@@ -1349,6 +1349,14 @@ LLPanelObjectInventory::LLPanelObjectInventory(const LLPanelObjectInventory::Par
// Destroys the object
LLPanelObjectInventory::~LLPanelObjectInventory()
{
+ if (mFolders)
+ {
+ mFolders->cancelRenaming();
+ if (LLEditMenuHandler::gEditMenuHandler == mFolders)
+ {
+ LLEditMenuHandler::gEditMenuHandler = NULL;
+ }
+ }
if (!gIdleCallbacks.deleteFunction(idle, this))
{
LL_WARNS() << "LLPanelObjectInventory::~LLPanelObjectInventory() failed to delete callback" << LL_ENDL;
@@ -1398,6 +1406,15 @@ void LLPanelObjectInventory::clearContents()
clearItemIDs();
+ if (mFolders)
+ {
+ mFolders->cancelRenaming();
+ if (LLEditMenuHandler::gEditMenuHandler == mFolders)
+ {
+ LLEditMenuHandler::gEditMenuHandler = NULL;
+ }
+ }
+
if( mScroller )
{
// removes mFolders
@@ -1780,6 +1797,14 @@ void LLPanelObjectInventory::draw()
void LLPanelObjectInventory::deleteAllChildren()
{
+ if (mFolders)
+ {
+ mFolders->cancelRenaming();
+ if (LLEditMenuHandler::gEditMenuHandler == mFolders)
+ {
+ LLEditMenuHandler::gEditMenuHandler = NULL;
+ }
+ }
mScroller = NULL;
mFolders = NULL;
LLView::deleteAllChildren();