[issue26423] Integer overflow in wrap_lenfunc() on 64-bit build of Windows

STINNER Victor report at bugs.python.org
Wed Feb 24 04:24:57 EST 2016


STINNER Victor added the comment:

> You need to call `x.__len__()` explicitly.

Ah ok :-) I didn't read carefully the initial message.

Attached patch should fix the issue on Python 2.7. It uses the same function than builtin_len() to cast the C Py_ssize_t to a Python int or long.

----------
keywords: +patch
Added file: http://bugs.python.org/file42017/wrap_lenfunc.patch

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue26423>
_______________________________________


More information about the Python-bugs-list mailing list