Fix bug ID 0000006 reported by leuk_he
Remove check for NumArg > 0. Always call va_start, va_end. git-svn-id: https://pupnp.svn.sourceforge.net/svnroot/pupnp/trunk@69 119443c7-1b9e-41f8-b6fc-b9c35fce742c
This commit is contained in:
@@ -348,14 +348,9 @@ UpnpMakeAction( const char *ActionName,
|
|||||||
va_list ArgList;
|
va_list ArgList;
|
||||||
IXML_Document *out = NULL;
|
IXML_Document *out = NULL;
|
||||||
|
|
||||||
if( NumArg > 0 ) {
|
va_start( ArgList, Arg );
|
||||||
va_start( ArgList, Arg );
|
|
||||||
}
|
|
||||||
|
|
||||||
out = makeAction( 0, ActionName, ServType, NumArg, Arg, ArgList );
|
out = makeAction( 0, ActionName, ServType, NumArg, Arg, ArgList );
|
||||||
if( NumArg > 0 ) {
|
va_end( ArgList );
|
||||||
va_end( ArgList );
|
|
||||||
}
|
|
||||||
|
|
||||||
return out;
|
return out;
|
||||||
}
|
}
|
||||||
@@ -390,14 +385,9 @@ UpnpMakeActionResponse( const char *ActionName,
|
|||||||
va_list ArgList;
|
va_list ArgList;
|
||||||
IXML_Document *out = NULL;
|
IXML_Document *out = NULL;
|
||||||
|
|
||||||
if( NumArg > 0 ) {
|
va_start( ArgList, Arg );
|
||||||
va_start( ArgList, Arg );
|
|
||||||
}
|
|
||||||
|
|
||||||
out = makeAction( 1, ActionName, ServType, NumArg, Arg, ArgList );
|
out = makeAction( 1, ActionName, ServType, NumArg, Arg, ArgList );
|
||||||
if( NumArg > 0 ) {
|
va_end( ArgList );
|
||||||
va_end( ArgList );
|
|
||||||
}
|
|
||||||
|
|
||||||
return out;
|
return out;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user