1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-01-09 17:38:00 +00:00

testcrypt: handle int as a return type.

I accepted both 'int' and 'uint' as function argument types, but
hadn't previously noticed that only 'uint' is handled properly as a
return type. Now both are.
This commit is contained in:
Simon Tatham 2020-01-06 19:57:51 +00:00
parent a6021a2f29
commit af72a11d54

View File

@ -176,7 +176,7 @@ def make_retval(rettype, word, unpack_strings):
retwords[0])
if rettype.startswith("val_"):
return Value(rettype, word)
elif rettype == "uint":
elif rettype == "int" or rettype == "uint":
return int(word, 0)
elif rettype == "boolean":
assert word == b"true" or word == b"false"