Salome HOME
Prepare version 1.2.1: quick fix for iteration 2 release
[modules/shaper.git] / src / Model / Model_Objects.cpp
index deadfd2a3c8b686c80147f0f0517e5de4135251f..54033a49b0e8c519d48f41d548692550fe8c5934 100644 (file)
@@ -340,6 +340,9 @@ ObjectPtr Model_Objects::object(TDF_Label theLabel)
 ObjectPtr Model_Objects::object(const std::string& theGroupID, const int theIndex)
 {
   createHistory(theGroupID);
+  //TODO: mpv stabilization hotfix
+  if (myHistory[theGroupID].size() <= theIndex)
+    return ObjectPtr();
   return myHistory[theGroupID][theIndex];
 }