From: asl Date: Fri, 10 Nov 2017 10:48:13 +0000 (+0300) Subject: patch for crash X-Git-Tag: v2.1~31^2 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=c68728637ee063231648aec9b9ab687db51a2ff5;p=modules%2Fhydro.git patch for crash --- diff --git a/src/HYDROGUI/HYDROGUI_ProfileDlg.cxx b/src/HYDROGUI/HYDROGUI_ProfileDlg.cxx index 92559c7b..239645b4 100644 --- a/src/HYDROGUI/HYDROGUI_ProfileDlg.cxx +++ b/src/HYDROGUI/HYDROGUI_ProfileDlg.cxx @@ -313,7 +313,12 @@ void HYDROGUI_ProfileDlg::SwitchToProfile(int theIndex) anAISObject->SetWidth(1); } } - (*myProfilesPointer)[0]->getDisplayer()->Update(); + + if( myProfilesPointer && + myProfilesPointer->size()>0 && + myProfilesPointer->at(0) && + myProfilesPointer->at(0)->getDisplayer() ) + myProfilesPointer->at(0)->getDisplayer()->Update(); } void HYDROGUI_ProfileDlg::onAddBtnPressed(bool)