[pypy-issue] [issue1569] PyArg_ParseTupleAndKeywords s# filling in incorrect size

Damien Miller tracker at bugs.pypy.org
Wed Jul 31 06:52:22 CEST 2013

New submission from Damien Miller <djm at djm.net.au>:


I just tried pypy (today head, JIT) for the first time and noticed that it compiles my py-bcrypt 
module but produces something that fails at runtime. To recreate the failure:

PYPY=/tmp/pypy/pypy/goal/pypy-c # or whatever
hg clone https://code.google.com/p/py-bcrypt/
cd py-bcrypt
$PYPY setup.py build
env PYTHONPATH=$PWD/build/lib.linux-x86_64-2.7/ $PYPY test/test.py

It looks like "s#" arguments extracted by PyArg_ParseTupleAndKeywords() are not being filled in 
correctly. For example, in py-bcrypt/bcrypt/bcrypt_python.c:bcrypt_hashpw() with a password of 
"" the corresponding password_len ends up being set to -4294967296.

I'm using Ubuntu Precise on x86_64.

messages: 6013
nosy: djm, pypy-issue
priority: bug
status: unread
title: PyArg_ParseTupleAndKeywords s# filling in incorrect size

PyPy bug tracker <tracker at bugs.pypy.org>

More information about the pypy-issue mailing list