]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
refs #202: segmentation violation when switch between modules
authornds <natalia.donis@opencascade.com>
Fri, 31 Oct 2014 06:36:11 +0000 (09:36 +0300)
committernds <natalia.donis@opencascade.com>
Fri, 31 Oct 2014 06:36:11 +0000 (09:36 +0300)
Disconnect NewGEOM from the viewer by the module deactivation

src/NewGeom/NewGeom_SalomeViewer.cpp

index a455bc183a8bd17683f384f8b01b05b58a65b982..fe9cd2310214d6a07099bc0564055e564f2b992d 100644 (file)
@@ -48,6 +48,9 @@ void NewGeom_SalomeViewer::setSelector(NewGeom_OCCSelector* theSel)
       return;
     else {
       mySelector->viewer()->getViewManager()->disconnect(this);
+      OCCViewer_Viewer* aViewer = mySelector->viewer();
+      if (aViewer)
+        aViewer->disconnect(this);
     }
   }
   mySelector = theSel;