diff options
author | simon <none@none> | 2013-10-16 12:06:42 -0700 |
---|---|---|
committer | simon <none@none> | 2013-10-16 12:06:42 -0700 |
commit | 913e55b5ce4c5e018d18678b9a78b06541976da1 (patch) | |
tree | b64eedc98a120950a16b050ad091e6938c88fea9 /indra | |
parent | 04b84ce07dd5bc8364f948ef0004e3dc5328f1b4 (diff) |
MAINT-3312 : crash in LLVOAvatar::lazyAttach(). Reverted some earlier changes
Diffstat (limited to 'indra')
-rwxr-xr-x | indra/newview/llvoavatar.cpp | 50 |
1 files changed, 33 insertions, 17 deletions
diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp index 6d29919784..f92fa0371e 100755 --- a/indra/newview/llvoavatar.cpp +++ b/indra/newview/llvoavatar.cpp @@ -5523,7 +5523,12 @@ void LLVOAvatar::addChild(LLViewerObject *childp) { if (!attachObject(childp)) { - mPendingAttachment.push_back(childp); + llwarns << "addChild() failed for " + << childp->getID() + << " item " << childp->getAttachmentItemID() + << llendl; + // MAINT-3312 backout + // mPendingAttachment.push_back(childp); } } else @@ -5557,21 +5562,26 @@ LLViewerJointAttachment* LLVOAvatar::getTargetAttachmentPoint(LLViewerObject* vi if (!attachment) { - llwarns << "Object attachment point invalid: " << attachmentID << llendl; + llwarns << "Object attachment point invalid: " << attachmentID + << " trying to use 1 (chest)" + << llendl; - for (int i = 0; i < 15 && !attachment; i++) + attachment = get_if_there(mAttachmentPoints, 1, (LLViewerJointAttachment*)NULL); // Arbitrary using 1 (chest) + if (attachment) { - attachment = get_if_there(mAttachmentPoints, i, (LLViewerJointAttachment*)NULL); // Arbitrary using 1 (chest) - - if (attachment) - { - llwarns << "Object attachment point falling back to : " << i << llendl; - } + llwarns << "Object attachment point invalid: " << attachmentID + << " on object " << viewer_object->getID() + << " attachment item " << viewer_object->getAttachmentItemID() + << " falling back to 1 (chest)" + << llendl; } - - if (!attachment) + else { - llerrs << "Could not find any object attachment point for: " << attachmentID << llendl; + llwarns << "Object attachment point invalid: " << attachmentID + << " on object " << viewer_object->getID() + << " attachment item " << viewer_object->getAttachmentItemID() + << "Unable to use fallback attachment point 1 (chest)" + << llendl; } } @@ -5643,16 +5653,22 @@ void LLVOAvatar::lazyAttach() for (U32 i = 0; i < mPendingAttachment.size(); i++) { - if (mPendingAttachment[i]->mDrawable) + LLPointer<LLViewerObject> cur_attachment = mPendingAttachment[i]; + if (cur_attachment->mDrawable) { - if (!attachObject(mPendingAttachment[i])) - { - still_pending.push_back(mPendingAttachment[i]); + if (!attachObject(cur_attachment)) + { // Drop it + llwarns << "attachObject() failed for " + << cur_attachment->getID() + << " item " << cur_attachment->getAttachmentItemID() + << llendl; + // MAINT-3312 backout + //still_pending.push_back(cur_attachment); } } else { - still_pending.push_back(mPendingAttachment[i]); + still_pending.push_back(cur_attachment); } } |