From ca5c4cc6ea4aa54000fe0e8729f9c14b8a59abfd Mon Sep 17 00:00:00 2001 From: dbv Date: Thu, 8 Sep 2016 10:16:55 +0300 Subject: [PATCH] Issue #1711: Dump study/Load saved script - tuple index out of range Fixed crash on dump exec --- src/Model/Model_SelectionNaming.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/Model/Model_SelectionNaming.cpp b/src/Model/Model_SelectionNaming.cpp index 567d4a867..75baa4744 100644 --- a/src/Model/Model_SelectionNaming.cpp +++ b/src/Model/Model_SelectionNaming.cpp @@ -410,6 +410,10 @@ size_t ParseName(const std::string& theSubShapeName, std::list& t const TopoDS_Shape findCommonShape( const TopAbs_ShapeEnum theType, const TopTools_ListOfShape& theList) { + if(theList.IsEmpty()) { + return TopoDS_Shape(); + } + TopoDS_Shape aShape; std::vector aVec; TopTools_MapOfShape aMap1, aMap2, aMap3, aMap4; -- 2.39.2