diff options
author | Mike Antipov <mantipov@productengine.com> | 2009-12-08 10:03:34 +0200 |
---|---|---|
committer | Mike Antipov <mantipov@productengine.com> | 2009-12-08 10:03:34 +0200 |
commit | d6e22a75791e6e82b1b4f4dad045e5b53129fe8d (patch) | |
tree | 996c1cd82e72e341db03f6317669ac188c49b0d0 /indra | |
parent | c3a82913deb9b23ef1f22b6d002893b36146553a (diff) |
Fixed major bug EXT-3191 (Crash after dragging inventory item to avatar or IM floater)
Reason: Null pointer to cargo data was passed from LLToolDragAndDrop::dragOrDrop in this case.
Fix: added check against NULL of the LLToolDragAndDrop::locateInventory() result in the LLToolDragAndDrop::dragOrDrop().
The same checking presents in another place of the LLToolDragAndDrop::dragOrDrop().
Handling is interrupted in this case.
Thanks Andrew ProductEngine for provided call stack
--HG--
branch : product-engine
Diffstat (limited to 'indra')
-rw-r--r-- | indra/newview/lltooldraganddrop.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/indra/newview/lltooldraganddrop.cpp b/indra/newview/lltooldraganddrop.cpp index 2d0a14dc70..aa35f22930 100644 --- a/indra/newview/lltooldraganddrop.cpp +++ b/indra/newview/lltooldraganddrop.cpp @@ -772,6 +772,9 @@ void LLToolDragAndDrop::dragOrDrop( S32 x, S32 y, MASK mask, BOOL drop, { LLInventoryObject* cargo = locateInventory(item, cat); + // fix for EXT-3191 + if (NULL == cargo) return; + EAcceptance item_acceptance = ACCEPT_NO; handled = handled && root_view->handleDragAndDrop(x, y, mask, FALSE, mCargoTypes[mCurItemIndex], |