From ea4f02821c3d388c3a937b8333aabeaadc62f4a5 Mon Sep 17 00:00:00 2001 From: mkr Date: Tue, 5 Sep 2006 07:03:48 +0000 Subject: [PATCH] Fix for bugs: 1) IPAL9273 (Application crashes after trying to close Graph Supervisor viewer with running dataflow) 2) IPAL9369 (3.0.0 (debianex: INSTALL2): CRASH after link deletion of the running dataflow) 3) IPAL9731 (CRASH after trying to kill dataflow execution) --- src/GraphExecutor/DataFlowExecutor_DynInvoke.cxx | 8 ++++++-- src/SUPERVGUI/SUPERVGUI_CanvasNodePrs.cxx | 5 ++++- src/SUPERVGUI/SUPERVGUI_Main.cxx | 4 +++- 3 files changed, 13 insertions(+), 4 deletions(-) diff --git a/src/GraphExecutor/DataFlowExecutor_DynInvoke.cxx b/src/GraphExecutor/DataFlowExecutor_DynInvoke.cxx index 157abdd..9d840c6 100644 --- a/src/GraphExecutor/DataFlowExecutor_DynInvoke.cxx +++ b/src/GraphExecutor/DataFlowExecutor_DynInvoke.cxx @@ -196,8 +196,12 @@ void GraphExecutor::InNode::DynInvoke(Engines::Component_ptr objComponent , #endif } - req->invoke(); - + // IPAL9273, 9369, 9731 : replace blocking function invoke() with non blocking send_deferred() + // to provide the correct process of killing dataflow execution + req->send_deferred() ; + while( !req->poll_response() ) {} + req->get_response(); + if( req->env()->exception() ) { req->env()->exception()->_raise() ; return ; // pas utile ? diff --git a/src/SUPERVGUI/SUPERVGUI_CanvasNodePrs.cxx b/src/SUPERVGUI/SUPERVGUI_CanvasNodePrs.cxx index 9fc76b7..c5d107d 100644 --- a/src/SUPERVGUI/SUPERVGUI_CanvasNodePrs.cxx +++ b/src/SUPERVGUI/SUPERVGUI_CanvasNodePrs.cxx @@ -777,7 +777,10 @@ void SUPERVGUI_CanvasNodePrs::setState(SUPERV::GraphState theState) break; } - long sec = myNode->getEngine()->CpuUsed(); + long sec = 0; + // IPAL9273, 9369, 9731 + if ( theState != SUPERV_Kill && myNode->getMain()->getDataflow()->State() != SUPERV_Kill ) + sec = myNode->getEngine()->CpuUsed(); char hms[9]; long s = sec/3600; hms[0]=(char)(((s/10)%10)+48); diff --git a/src/SUPERVGUI/SUPERVGUI_Main.cxx b/src/SUPERVGUI/SUPERVGUI_Main.cxx index d62e781..deb10c2 100644 --- a/src/SUPERVGUI/SUPERVGUI_Main.cxx +++ b/src/SUPERVGUI/SUPERVGUI_Main.cxx @@ -756,7 +756,9 @@ void SUPERVGUI_Main::kill() { QMessageBox::warning(SUIT_Session::session()->activeApplication()->desktop(), tr("ERROR"), tr("MSG_DF_NOTRUNNING")); } else if (dataflow->Kill()) { - getMessage()->putMessage( tr("MSG_GRAPH_KILLED") ); + // IPAL9273, 9369, 9731 : to avoid two equal messages about killing dataflow + // execution in the Message Console + //getMessage()->putMessage( tr("MSG_GRAPH_KILLED") ); sync(); } else { -- 2.39.2