diff options
Diffstat (limited to 'upstream/parameter/Element.cpp')
| -rw-r--r-- | upstream/parameter/Element.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/upstream/parameter/Element.cpp b/upstream/parameter/Element.cpp index 8317299..611951c 100644 --- a/upstream/parameter/Element.cpp +++ b/upstream/parameter/Element.cpp @@ -31,6 +31,7 @@ #include "XmlElementSerializingContext.h" #include "ElementLibrary.h" #include "ErrorContext.hpp" +#include "PfError.hpp" #include <algorithm> #include <assert.h> #include <stdio.h> @@ -140,8 +141,8 @@ string CElement::logValue(utility::ErrorContext & /*ctx*/) const } // From IXmlSink -bool CElement::fromXml(const CXmlElement &xmlElement, CXmlSerializingContext &serializingContext) -{ +bool CElement::fromXml(const CXmlElement &xmlElement, + CXmlSerializingContext &serializingContext) try { xmlElement.getAttribute(gDescriptionPropertyName, _strDescription); // Propagate through children @@ -183,6 +184,9 @@ bool CElement::fromXml(const CXmlElement &xmlElement, CXmlSerializingContext &se } return true; +} catch (const PfError &e) { + serializingContext.appendLineToError(e.what()); + return false; } void CElement::childrenToXml(CXmlElement &xmlElement, |
