From 211aeeb9adc727df0cf793ce503b707ae453bf49 Mon Sep 17 00:00:00 2001 From: maintenance team Date: Wed, 27 Sep 2006 12:46:51 +0000 Subject: [PATCH] Correction for problem: Execution of the wrong dataflow has "DoneState" status instead of "ErrorState"(int type used instead of long for portability) --- src/GraphExecutor/DataFlowExecutor_PyDynInvoke.cxx | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/GraphExecutor/DataFlowExecutor_PyDynInvoke.cxx b/src/GraphExecutor/DataFlowExecutor_PyDynInvoke.cxx index 8f13356..d885612 100644 --- a/src/GraphExecutor/DataFlowExecutor_PyDynInvoke.cxx +++ b/src/GraphExecutor/DataFlowExecutor_PyDynInvoke.cxx @@ -370,7 +370,14 @@ bool GraphExecutor::InNode::PyDynInvoke( PyObject * MyPyRunMethod , case CORBA::tk_long : { CORBA::Long l ; data >>= l ; - PyObject * ArgValue = Py_BuildValue( "l" , l ) ; +// epa - Porting to 64-bit Linux:CORBA::Long is incorrectly treated as unsigned +// integer by Py_BuildValue("l", val) in Python 2.4.1. Using Py_BuildValue("i",val) +// seemsto help + PyObject * ArgValue = NULL; + if ( SIZEOF_LONG == 4 ) + ArgValue = Py_BuildValue( "l" , l ) ; + else + ArgValue = Py_BuildValue( "i" , l ) ; #if PyDynInvokeTrace cdebug << "ArgIn" << i << " : " << sname << " " << method << " Value " << l << " ArgValue->ob_refcnt" << ArgValue->ob_refcnt << endl ; -- 2.39.2