From: spo Date: Tue, 24 May 2016 13:09:52 +0000 (+0300) Subject: Model_Data sends an error if attribute doesn't exist X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=434bd7ae4f4d69996eac4b0fa3fba33ac01faec0;p=modules%2Fshaper.git Model_Data sends an error if attribute doesn't exist --- diff --git a/src/Model/Model_Data.cpp b/src/Model/Model_Data.cpp index 1844bde49..84548b6df 100644 --- a/src/Model/Model_Data.cpp +++ b/src/Model/Model_Data.cpp @@ -195,6 +195,8 @@ AttributePtr Model_Data::addAttribute(const std::string& theID, const std::strin myAttrs.find(theID); \ if (aFound != myAttrs.end()) { \ aRes = std::dynamic_pointer_cast(aFound->second); \ + } else { \ + Events_Error::send("Can not receive unknown attribute " + theID + " of type " + #ATTR_TYPE); \ } \ return aRes; \ }