UINT16 timeout;
UINT16 timeout = 0;
PyObject* wpSocket_attachtarget( wpSocket* self, PyObject* args ){	if( !self->pSock )		return PyFalse;	if( !checkArgStr( 0 ) )	{		PyErr_BadArgument();		return NULL;	}	// Collect Data	QString responsefunc = getArgStr( 0 );	QString cancelfunc, timeoutfunc;	UINT16 timeout;	PyObject *targetargs = 0;	// If Second argument is present, it has to be a tuple	if( PyTuple_Size( args ) > 1 && PyList_Check( PyTuple_GetItem( args, 1 ) ) )		targetargs = PyList_AsTuple( PyTuple_GetItem( args, 1 ) );	if( !targetargs )		targetargs = PyTuple_New( 0 );	if( checkArgStr( 2 ) )		cancelfunc = getArgStr( 2 );	if( checkArgStr( 3 ) && checkArgInt( 4 ) )	{		timeoutfunc = getArgStr( 3 );		timeout = getArgInt( 4 );	}	cPythonTarget *target = new cPythonTarget( responsefunc, timeoutfunc, cancelfunc, targetargs );	target->setTimeout( uiCurrentTime + timeout );	self->pSock->attachTarget( target );	return PyTrue;}