bos #30314 EDF 25565 - Strange behavior on a specific case

Avoid SIGSEGV when returning NULL instead of an empty list
This commit is contained in:
eap 2022-06-17 19:02:28 +03:00
parent 9d7121c884
commit 678de41423

View File

@ -3664,7 +3664,7 @@ SMESH_MeshEditor_i::TranslateMakeGroups(const SMESH::smIdType_array& theIDsOfEle
<< theIDsOfElements << ", " << theIDsOfElements << ", "
<< theVector << " )"; << theVector << " )";
} }
return aGroups; return aGroups ? aGroups : new SMESH::ListOfGroups();
} }
//======================================================================= //=======================================================================
@ -3689,7 +3689,7 @@ SMESH_MeshEditor_i::TranslateObjectMakeGroups(SMESH::SMESH_IDSource_ptr theObjec
<< theObject << ", " << theObject << ", "
<< theVector << " )"; << theVector << " )";
} }
return aGroups; return aGroups ? aGroups : new SMESH::ListOfGroups();
} }
//======================================================================= //=======================================================================
@ -3914,7 +3914,7 @@ SMESH_MeshEditor_i::RotateMakeGroups(const SMESH::smIdType_array& theIDsOfElemen
<< theAxis << ", " << theAxis << ", "
<< TVar( theAngle ) << " )"; << TVar( theAngle ) << " )";
} }
return aGroups; return aGroups ? aGroups : new SMESH::ListOfGroups();
} }
//======================================================================= //=======================================================================
@ -3941,7 +3941,7 @@ SMESH_MeshEditor_i::RotateObjectMakeGroups(SMESH::SMESH_IDSource_ptr theObject,
<< theAxis << ", " << theAxis << ", "
<< TVar( theAngle ) << " )"; << TVar( theAngle ) << " )";
} }
return aGroups; return aGroups ? aGroups : new SMESH::ListOfGroups();
} }
//======================================================================= //=======================================================================