Author: tpot Date: 2004-10-14 13:09:59 +0000 (Thu, 14 Oct 2004) New Revision: 2975
WebSVN: http://websvn.samba.org/websvn/changeset.php?rep=samba&path=/branches/SAMBA_4_0/source/scripting/swig&rev=2975&nolog=1 Log: Try to emulate NT_STATUS_IS_ERR() functionality for WERRORs. Unfortunately this means enumerating all the ones we don't think are errors. Modified: branches/SAMBA_4_0/source/scripting/swig/dcerpc.i Changeset: Modified: branches/SAMBA_4_0/source/scripting/swig/dcerpc.i =================================================================== --- branches/SAMBA_4_0/source/scripting/swig/dcerpc.i 2004-10-14 11:11:21 UTC (rev 2974) +++ branches/SAMBA_4_0/source/scripting/swig/dcerpc.i 2004-10-14 13:09:59 UTC (rev 2975) @@ -286,7 +286,6 @@ %} %include "samba.i" -%include "status_codes.i" %pythoncode %{ NTSTATUS = _dcerpc.NTSTATUS @@ -370,7 +369,8 @@ set_ntstatus_exception(NT_STATUS_V(result)); return NULL; } - if (!W_ERROR_IS_OK(arg3->out.result)) { + if (!W_ERROR_IS_OK(arg3->out.result) && + !(W_ERROR_EQUAL(arg3->out.result, WERR_INSUFFICIENT_BUFFER))) { set_werror_exception(W_ERROR_V(arg3->out.result)); return NULL; } @@ -378,3 +378,5 @@ %include "librpc/gen_ndr/winreg.i" %include "librpc/gen_ndr/spoolss.i" + +%include "status_codes.i"