diff options
author | Diva Canto | 2012-09-22 14:01:51 -0700 |
---|---|---|
committer | Diva Canto | 2012-09-22 14:01:51 -0700 |
commit | 87d810217e2675880bec68891431bd5d422cb1b8 (patch) | |
tree | bcfb7c3571107aed872d557f653aa78d75ab3759 /OpenSim/Region/CoreModules/Avatar/Attachments | |
parent | Make BaseHttpServer throws say something useful. (diff) | |
download | opensim-SC_OLD-87d810217e2675880bec68891431bd5d422cb1b8.zip opensim-SC_OLD-87d810217e2675880bec68891431bd5d422cb1b8.tar.gz opensim-SC_OLD-87d810217e2675880bec68891431bd5d422cb1b8.tar.bz2 opensim-SC_OLD-87d810217e2675880bec68891431bd5d422cb1b8.tar.xz |
Guard against inventory get failures.
Diffstat (limited to 'OpenSim/Region/CoreModules/Avatar/Attachments')
-rw-r--r-- | OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs index d6ad07e..c74584c 100644 --- a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs | |||
@@ -859,6 +859,9 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments | |||
859 | 859 | ||
860 | InventoryItemBase item = new InventoryItemBase(itemID, sp.UUID); | 860 | InventoryItemBase item = new InventoryItemBase(itemID, sp.UUID); |
861 | item = m_scene.InventoryService.GetItem(item); | 861 | item = m_scene.InventoryService.GetItem(item); |
862 | if (item == null) | ||
863 | return; | ||
864 | |||
862 | bool changed = sp.Appearance.SetAttachment((int)AttachmentPt, itemID, item.AssetID); | 865 | bool changed = sp.Appearance.SetAttachment((int)AttachmentPt, itemID, item.AssetID); |
863 | if (changed && m_scene.AvatarFactory != null) | 866 | if (changed && m_scene.AvatarFactory != null) |
864 | { | 867 | { |