mirror of
https://github.com/samba-team/samba.git
synced 2025-07-30 19:42:05 +03:00
s4/scripting/autoidl: py3 compatible except
Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Noel Power <noel.power@suse.com>
This commit is contained in:
committed by
Douglas Bagnall
parent
8532308883
commit
f109fde362
@ -37,8 +37,8 @@ def find_num_funcs(conn):
|
||||
for i in xrange(MAX_OPNUM):
|
||||
try:
|
||||
conn.request(i, "")
|
||||
except RuntimeError, (num, msg):
|
||||
if num == DCERPC_FAULT_OP_RNG_ERROR:
|
||||
except RuntimeError as e:
|
||||
if e.args[0] == DCERPC_FAULT_OP_RNG_ERROR:
|
||||
return i
|
||||
raise Exception("More than %d functions" % MAX_OPNUM)
|
||||
|
||||
|
Reference in New Issue
Block a user