From d956fb60db79a04e21e082a2fcef85e57cfc22db Mon Sep 17 00:00:00 2001 From: Kitty Barnett Date: Sun, 10 Jul 2016 22:39:06 +0200 Subject: [PATCH] [FIXED] Strict versions of restictions fail with "unknown command" -> additionally, revert to using the stored string behaviour otherwise @sendim_sec=n,getstatus=0 shows /sendim rather than /sendim_sec --HG-- branch : RLVa --- indra/newview/rlvhelper.cpp | 2 +- indra/newview/rlvhelper.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/indra/newview/rlvhelper.cpp b/indra/newview/rlvhelper.cpp index 80929deceb..fde6a6e4bc 100644 --- a/indra/newview/rlvhelper.cpp +++ b/indra/newview/rlvhelper.cpp @@ -357,7 +357,7 @@ const RlvBehaviourInfo* RlvBehaviourDictionary::getBehaviourInfo(const std::stri if (pfStrict) *pfStrict = fStrict; - rlv_string2info_map_t::const_iterator itBhvr = m_String2InfoMap.find(std::make_pair(strBhvr, (eParamType & RLV_TYPE_ADDREM) ? RLV_TYPE_ADDREM : eParamType)); + rlv_string2info_map_t::const_iterator itBhvr = m_String2InfoMap.find(std::make_pair( (!fStrict) ? strBhvr : strBhvr.substr(0, strBhvr.size() - 4), (eParamType & RLV_TYPE_ADDREM) ? RLV_TYPE_ADDREM : eParamType)); return ( (itBhvr != m_String2InfoMap.end()) && ((!fStrict) || (itBhvr->second->hasStrict())) ) ? itBhvr->second : NULL; } diff --git a/indra/newview/rlvhelper.h b/indra/newview/rlvhelper.h index 72b157ec94..f9bb093bee 100644 --- a/indra/newview/rlvhelper.h +++ b/indra/newview/rlvhelper.h @@ -385,7 +385,7 @@ public: */ public: std::string asString() const; - const std::string& getBehaviour() const { return (m_pBhvrInfo) ? m_pBhvrInfo->getBehaviour() : m_strBehaviour; } + const std::string& getBehaviour() const { return m_strBehaviour; } ERlvBehaviour getBehaviourType() const { return (m_pBhvrInfo) ? m_pBhvrInfo->getBehaviourType() : RLV_BHVR_UNKNOWN; } U32 getBehaviourFlags() const{ return (m_pBhvrInfo) ? m_pBhvrInfo->getBehaviourFlags() : 0; } const LLUUID& getObjectID() const { return m_idObj; }