some additions to pR 1794:

add a special XMLAttributeError class to indicate an error when accessing a missing attribute
in PropertyContainer::Restore make error handling more flexible
This commit is contained in:
wmayer
2018-11-19 19:07:56 +01:00
parent 7216dba2f3
commit ddb20468ad
7 changed files with 71 additions and 19 deletions

View File

@@ -3729,7 +3729,7 @@ void GeomLineSegment::Restore (Base::XMLReader &reader)
try {
setPoints(start, end);
}
catch(Base::ValueError &e) {
catch(Base::ValueError&) {
// for a line segment construction, the only possibility of a value error is that
// the points are too close. The best try to restore is incrementing the distance.
// for other objects, the best effort may be just to leave default values.