Fix gdb.Value->python conversion for large unsigned ints.

gdb/ChangeLog:

	* python/py-value.c (valpy_long): Handle unsigned values.

gdb/testsuite/ChangeLog:

	* gdb.python/py-value.exp (test_value_creation): Add test for large
	unsigned 64-bit value.
This commit is contained in:
Doug Evans 2016-10-06 10:41:27 -07:00
parent d73f9c4bab
commit 33fa2c6e1b
4 changed files with 18 additions and 1 deletions

View file

@ -1518,7 +1518,10 @@ valpy_long (PyObject *self)
}
END_CATCH
return gdb_py_long_from_longest (l);
if (TYPE_UNSIGNED (type))
return gdb_py_long_from_ulongest (l);
else
return gdb_py_long_from_longest (l);
}
/* Implements conversion to float. */