MAINT-813 FIXED Potential fix for a crash at LLViewerRegion::getPosGlobalFromRegion.

As far as I can tell, if login fails with the "Region has begun the logout process" message, gAgentAvatarp gets destroyed, which leads to the crash.
Adding a check that should prevent it (could not reproduce to make sure).
meow-7.2.2
Vadim ProductEngine 2012-03-30 15:45:54 +03:00
parent 886d743a18
commit eb9e6e295d
1 changed files with 4 additions and 1 deletions

View File

@ -143,7 +143,10 @@ LLViewerObject *LLViewerObject::createObject(const LLUUID &id, const LLPCode pco
}
else
{
gAgentAvatarp->updateRegion(regionp);
if (isAgentAvatarValid())
{
gAgentAvatarp->updateRegion(regionp);
}
}
res = gAgentAvatarp;
}