summaryrefslogtreecommitdiff
path: root/indra/newview/llviewerobject.cpp
diff options
context:
space:
mode:
authorXiaohong Bao <bao@lindenlab.com>2013-04-17 23:01:11 -0600
committerXiaohong Bao <bao@lindenlab.com>2013-04-17 23:01:11 -0600
commit04d0d5a3ab0285f0d3acc7581cea6809343e86ab (patch)
treedd998bb8ba103d06d9b8df699cbfe44735a54a99 /indra/newview/llviewerobject.cpp
parentdc261cbe4c7b1de8943f00218d62ab6180e7cfad (diff)
parent674df12bc9e81b9b4290f74a96116dbbf1e7f77c (diff)
Automated merge with ssh://hg.lindenlab.com/richard/viewer-interesting
Diffstat (limited to 'indra/newview/llviewerobject.cpp')
-rw-r--r--indra/newview/llviewerobject.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/indra/newview/llviewerobject.cpp b/indra/newview/llviewerobject.cpp
index d5d804bc57..ef28c3ad53 100644
--- a/indra/newview/llviewerobject.cpp
+++ b/indra/newview/llviewerobject.cpp
@@ -995,7 +995,13 @@ U32 LLViewerObject::checkMediaURL(const std::string &media_url)
U32 LLViewerObject::extractSpatialExtents(LLDataPackerBinaryBuffer *dp, LLVector3& pos, LLVector3& scale, LLQuaternion& rot)
{
U32 parent_id = 0;
-
+ LLViewerObject::unpackParentID(dp, parent_id);
+ if(parent_id > 0)
+ {
+ //is a child, no need to decode further.
+ return parent_id;
+ }
+
LLViewerObject::unpackVector3(dp, scale, "Scale");
LLViewerObject::unpackVector3(dp, pos, "Pos");
@@ -1003,8 +1009,6 @@ U32 LLViewerObject::extractSpatialExtents(LLDataPackerBinaryBuffer *dp, LLVector
LLViewerObject::unpackVector3(dp, vec, "Rot");
rot.unpackFromVector3(vec);
- LLViewerObject::unpackParentID(dp, parent_id);
-
return parent_id;
}