diff options
author | Richard Linden <none@none> | 2012-10-25 17:30:03 -0700 |
---|---|---|
committer | Richard Linden <none@none> | 2012-10-25 17:30:03 -0700 |
commit | 7f97aa2d5db0d1429136a40d04d2e4428cb184fe (patch) | |
tree | beac059a2c447c1d4ad0d3f3fa6d6ff1e942358c /indra | |
parent | 1de6ecb23851e0784016a2c4c9f691c976c6bda7 (diff) |
SH-3405 WIP convert existing stats to lltrace system
fixed crash on exit
Diffstat (limited to 'indra')
-rw-r--r-- | indra/llcommon/llinitparam.h | 13 | ||||
-rw-r--r-- | indra/llui/llxuiparser.cpp | 10 | ||||
-rw-r--r-- | indra/llxml/llxmlnode.cpp | 3 |
3 files changed, 11 insertions, 15 deletions
diff --git a/indra/llcommon/llinitparam.h b/indra/llcommon/llinitparam.h index a3a5b3dc37..9530e562f6 100644 --- a/indra/llcommon/llinitparam.h +++ b/indra/llcommon/llinitparam.h @@ -916,7 +916,6 @@ namespace LLInitParam { predicate.add(NON_DEFAULT); } - predicate.unknown(REQUIRED); if (typed_param.isValid()) { predicate.add(VALID); @@ -1074,8 +1073,6 @@ namespace LLInitParam const self_t& typed_param = static_cast<const self_t&>(param); LLPredicate::Value<ESerializePredicates> predicate; - predicate.unknown(NON_DEFAULT); - predicate.unknown(REQUIRED); if (typed_param.isValid()) { @@ -1272,16 +1269,11 @@ namespace LLInitParam const self_t& typed_param = static_cast<const self_t&>(param); LLPredicate::Value<ESerializePredicates> predicate; - predicate.unknown(NON_DEFAULT); if (typed_param.mMinCount > 0) { predicate.add(REQUIRED); } - else - { - predicate.unknown(REQUIRED); - } if (typed_param.isValid()) { @@ -1538,16 +1530,11 @@ namespace LLInitParam const self_t& typed_param = static_cast<const self_t&>(param); LLPredicate::Value<ESerializePredicates> predicate; - predicate.unknown(NON_DEFAULT); if (typed_param.mMinCount > 0) { predicate.add(REQUIRED); } - else - { - predicate.unknown(REQUIRED); - } if (typed_param.isValid()) { diff --git a/indra/llui/llxuiparser.cpp b/indra/llui/llxuiparser.cpp index 179a1184af..95cda92632 100644 --- a/indra/llui/llxuiparser.cpp +++ b/indra/llui/llxuiparser.cpp @@ -880,16 +880,24 @@ LLXMLNodePtr LLXUIParser::getNode(name_stack_t& stack) it = next_it) { ++next_it; + bool force_new_node = false; + if (it->first.empty()) { it->second = false; continue; } + if (next_it != stack.end() && next_it->first.empty() && next_it->second) + { + force_new_node = true; + } + + out_nodes_t::iterator found_it = mOutNodes.find(it->first); // node with this name not yet written - if (found_it == mOutNodes.end() || it->second) + if (found_it == mOutNodes.end() || it->second || force_new_node) { // make an attribute if we are the last element on the name stack bool is_attribute = next_it == stack.end(); diff --git a/indra/llxml/llxmlnode.cpp b/indra/llxml/llxmlnode.cpp index 2ffb0d8503..8746114f1b 100644 --- a/indra/llxml/llxmlnode.cpp +++ b/indra/llxml/llxmlnode.cpp @@ -273,7 +273,8 @@ void LLXMLNode::addChild(LLXMLNodePtr new_child, LLXMLNodePtr after_child) new_child->mParent = this; if (new_child->mIsAttribute) { - mAttributes.insert(std::make_pair(new_child->mName, new_child)); + std::pair<LLXMLAttribList::iterator, bool> result = mAttributes.insert(std::make_pair(new_child->mName, new_child)); + llassert(result.second); } else { |