diff options
author | Justin Clarke Casey | 2008-07-08 16:57:48 +0000 |
---|---|---|
committer | Justin Clarke Casey | 2008-07-08 16:57:48 +0000 |
commit | 00a38df75a254e7d88c0a69d8863b55e1c2a9667 (patch) | |
tree | b16fb99ade0010a07166e6381bc8477ffcc6f8c8 /OpenSim/Region/Environment/Scenes/Scene.Inventory.cs | |
parent | small console message change related to last revision (diff) | |
download | opensim-SC-00a38df75a254e7d88c0a69d8863b55e1c2a9667.zip opensim-SC-00a38df75a254e7d88c0a69d8863b55e1c2a9667.tar.gz opensim-SC-00a38df75a254e7d88c0a69d8863b55e1c2a9667.tar.bz2 opensim-SC-00a38df75a254e7d88c0a69d8863b55e1c2a9667.tar.xz |
* Guard against a failure to find an inventory item in a move request by complaining in the log rather than terminating the session
Diffstat (limited to 'OpenSim/Region/Environment/Scenes/Scene.Inventory.cs')
-rw-r--r-- | OpenSim/Region/Environment/Scenes/Scene.Inventory.cs | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs index b479fed..b0e4a87 100644 --- a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs +++ b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs | |||
@@ -968,12 +968,19 @@ namespace OpenSim.Region.Environment.Scenes | |||
968 | } | 968 | } |
969 | 969 | ||
970 | TaskInventoryItem taskItem = part.GetInventoryItem(itemId); | 970 | TaskInventoryItem taskItem = part.GetInventoryItem(itemId); |
971 | |||
972 | if (null == taskItem) | ||
973 | { | ||
974 | m_log.WarnFormat("[PRIM INVENTORY]: Move of inventory item {0} from prim with local id {1} failed" | ||
975 | + " because the inventory item could not be found", | ||
976 | itemId, primLocalId); | ||
977 | |||
978 | return; | ||
979 | } | ||
971 | 980 | ||
972 | // Only owner can copy | 981 | // Only owner can copy |
973 | if (remoteClient.AgentId != taskItem.OwnerID) | 982 | if (remoteClient.AgentId != taskItem.OwnerID) |
974 | { | ||
975 | return; | 983 | return; |
976 | } | ||
977 | 984 | ||
978 | MoveTaskInventoryItem(remoteClient, folderId, part, itemId); | 985 | MoveTaskInventoryItem(remoteClient, folderId, part, itemId); |
979 | } | 986 | } |