From 9fcabdbcf7d88029e20d9a6876b8323b2c3c6c0c Mon Sep 17 00:00:00 2001 From: mpv Date: Thu, 23 Jun 2016 19:36:39 +0300 Subject: [PATCH] Fix for crash on changing of creation modes or already created arc --- src/ModelAPI/ModelAPI_Tools.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/ModelAPI/ModelAPI_Tools.cpp b/src/ModelAPI/ModelAPI_Tools.cpp index 8d0b8f018..7a7bbecb7 100755 --- a/src/ModelAPI/ModelAPI_Tools.cpp +++ b/src/ModelAPI/ModelAPI_Tools.cpp @@ -359,6 +359,8 @@ bool hasSubResults(const ResultPtr& theResult) void allResults(const FeaturePtr& theFeature, std::list& theResults) { + if (!theFeature.get()) // safety: for empty feature no results + return; const std::list >& aResults = theFeature->results(); std::list >::const_iterator aRIter = aResults.begin(); for (; aRIter != aResults.cend(); aRIter++) { -- 2.39.2