From c860a5706f3b2cdd9628f8151e55d4bc6399ce54 Mon Sep 17 00:00:00 2001 From: mkr Date: Mon, 6 Feb 2006 14:54:33 +0000 Subject: [PATCH] Fix for bug PAL8150 : CRASH after "Put in Study" applied to the "readMeshInFile" node. --- src/SUPERVGUI/SUPERVGUI_Main.cxx | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/SUPERVGUI/SUPERVGUI_Main.cxx b/src/SUPERVGUI/SUPERVGUI_Main.cxx index bd23eaa..6cd32b7 100644 --- a/src/SUPERVGUI/SUPERVGUI_Main.cxx +++ b/src/SUPERVGUI/SUPERVGUI_Main.cxx @@ -564,7 +564,7 @@ void SUPERVGUI_Main::onShowToolbar() aVF->getToolBar()->show(); } -// mkr : PAL8237 : synchronize many views of the same dataflow +// mkr : PAL8237 : synchronize many views of the same dataflow (objects creation/deletion) void SUPERVGUI_Main::onObjectCreatedDeleted() { if ( study ) { @@ -1097,7 +1097,12 @@ bool SUPERVGUI_Main::putDataStudy( SUPERV_Port p, const char* inout ) { SALOMEDS::SObject_var aTmpSO;// = aSO; SALOMEDS_Study* aSStudy = dynamic_cast( aStudy.get() ); if ( !aSStudy ) return false; - aTmpSO = aDriver->PublishInStudy( aSStudy->GetStudy(), aTmpSO, anObject, "" ); + try { + aTmpSO = aDriver->PublishInStudy( aSStudy->GetStudy(), aTmpSO, anObject, "" ); + } + catch ( ... ) { // mkr : PAL8150 + return false; + } aBuilder->Addreference(aSO, _PTR(SObject)(new SALOMEDS_SObject( aTmpSO )) ); PublishOtherComponent = true; } -- 2.39.2