If attachment fails (e.g. because asset wasn't found) then don't try to set attachment as shown in inventory

Doing this results in a null reference exception
viewer-2-initial-appearance
Justin Clark-Casey (justincc) 2010-09-13 20:58:50 +01:00
parent ff098ae110
commit 366de0a7b5
1 changed files with 2 additions and 4 deletions

View File

@ -233,11 +233,9 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
if (updateInventoryStatus)
{
if (att == null)
{
ShowDetachInUserInventory(itemID, remoteClient);
}
SetAttachmentInventoryStatus(att, remoteClient, itemID, AttachmentPt);
else
SetAttachmentInventoryStatus(att, remoteClient, itemID, AttachmentPt);
}
if (null == att)