Salome HOME
IPAL54425: Quadrangle mapping fails on a quadrangle face with a seam
[modules/smesh.git] / src / SMESH_I / SMESH_2smeshpy.cxx
index 45540d510a4f8157a2df1b610317ab85c87aeb4a..b22af73ebdb34d756c8a7364e697759a19b80f68 100644 (file)
@@ -1971,7 +1971,7 @@ void _pyMesh::Process( const Handle(_pyCommand)& theCommand )
       if ( !obj->CanClear() )
         allGroupsRemoved = false;
     }
-    if ( nbGroupsBefore == myGroups.size() ) // no new _pyGroup created
+    if ( nbGroupsBefore == myGroups.size() && !obj.IsNull() ) // no new _pyGroup created
       obj->AddProcessedCmd( theCommand ); // to clear theCommand if all groups are removed
 
     if ( !allGroupsRemoved && !theGen->IsToKeepAllCommands() )