From b62e6fb0c127ead9a674a495f8e91b96f01c461a Mon Sep 17 00:00:00 2001 From: Damien Dupuis Date: Mon, 30 May 2011 11:22:02 +0000 Subject: [PATCH] Bug correction : in PyBox.inflate method : third and fourth arguments were not initialized by Parse_Tuple leadding to a segmentation fault when using inflate with 4 arguments in python. --- hurricane/src/isobar/PyBox.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/hurricane/src/isobar/PyBox.cpp b/hurricane/src/isobar/PyBox.cpp index b5494039..b9cb6adb 100644 --- a/hurricane/src/isobar/PyBox.cpp +++ b/hurricane/src/isobar/PyBox.cpp @@ -259,13 +259,13 @@ extern "C" { PyObject* arg0; PyObject* arg1; - PyObject* arg2 = NULL; - PyObject* arg3 = NULL; + PyObject* arg2; + PyObject* arg3; HTRY __cs.init ("Box.inflate"); - if ( ! PyArg_ParseTuple(args,"|O&O&O&O&:Box.inflate",Converter,&arg0,Converter,&arg1) ) + if ( ! PyArg_ParseTuple(args,"|O&O&O&O&:Box.inflate",Converter,&arg0,Converter,&arg1,Converter,&arg2,Converter,&arg3) ) return ( NULL ); if ( __cs.getObjectIds() == INT_ARG ) { box->inflate ( PyInt_AsLong(arg0) ); }