Fix crash in LLControlAvatar::matchVolumeTransform() from Kitty Barnett

This commit is contained in:
Liru Færs
2020-01-05 15:44:31 -05:00
parent 2117c66c9a
commit 5574f263b1
2 changed files with 15 additions and 0 deletions

View File

@@ -325,6 +325,20 @@ void LLControlAvatar::markForDeath()
mRootVolp = NULL;
}
void LLControlAvatar::markDead()
{
// NOTE: this can happen when the control avatar and root volume are on different regions and we're
// being called from the LLViewerRegion destructor due the region being dropped
// (due to being used as a vehicle and the move not yet being processed?)
if (mRootVolp)
{
mRootVolp->unlinkControlAvatar();
mRootVolp = nullptr;
}
LLVOAvatar::markDead();
}
void LLControlAvatar::idleUpdate(LLAgent &agent, LLWorld &world, const F64 &time)
{
if (mMarkedForDeath)

View File

@@ -52,6 +52,7 @@ public:
// Delayed kill so we don't make graphics pipeline unhappy calling
// markDead() inside other graphics pipeline operations.
void markForDeath();
void markDead() override;
void idleUpdate(LLAgent &agent, LLWorld &world, const F64 &time) override;
BOOL updateCharacter(LLAgent &agent) override;