Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(7)

#28261: wrong error messages when using PyArg_ParseTuple to parse normal tuples

Can't Edit
Can't Publish+Mail
Start Review
Created:
3 years, 5 months ago by orenmn
Modified:
2 years, 6 months ago
Reviewers:
storchaka+cpython
CC:
rhettinger, haypo, storchaka, Oren Milman
Visibility:
Public.

Patch Set 1 #

Total comments: 7
Unified diffs Side-by-side diffs Delta from patch set Stats Patch
Modules/audioop.c View 3 chunks +9 lines, -4 lines 2 comments Download
Modules/_ctypes/_ctypes.c View 1 chunk +4 lines, -1 line 2 comments Download
Modules/_io/textio.c View 1 chunk +4 lines, -1 line 0 comments Download
Modules/itertoolsmodule.c View 5 chunks +21 lines, -7 lines 0 comments Download
Modules/overlapped.c View 1 chunk +3 lines, -1 line 3 comments Download
Modules/socketmodule.c View 1 chunk +5 lines, -3 lines 0 comments Download

Messages

Total messages: 3
storchaka
http://bugs.python.org/review/28261/diff/18651/Modules/_ctypes/_ctypes.c File Modules/_ctypes/_ctypes.c (right): http://bugs.python.org/review/28261/diff/18651/Modules/_ctypes/_ctypes.c#newcode3254 Modules/_ctypes/_ctypes.c:3254: "O&O;PyCFuncPtr.__new__: illegal function name and " I think it ...
2 years, 11 months ago #1
Oren Milman
http://bugs.python.org/review/28261/diff/18651/Modules/_ctypes/_ctypes.c File Modules/_ctypes/_ctypes.c (right): http://bugs.python.org/review/28261/diff/18651/Modules/_ctypes/_ctypes.c#newcode3254 Modules/_ctypes/_ctypes.c:3254: "O&O;PyCFuncPtr.__new__: illegal function name and " On 2017/03/03 08:34:36, ...
2 years, 6 months ago #2
storchaka
2 years, 6 months ago #3
https://bugs.python.org/review/28261/diff/18651/Modules/overlapped.c
File Modules/overlapped.c (right):

https://bugs.python.org/review/28261/diff/18651/Modules/overlapped.c#newcode983
Modules/overlapped.c:983: if (PyArg_ParseTuple(obj, "uH", &Host, &Port))
On 2017/08/16 16:09:26, Oren Milman wrote:
> On 2017/03/03 08:34:36, storchaka wrote:
> > Doesn't this need an error message too?
> 
> ISTM that it doesn't, because in case the first PyArg_ParseTuple fails, the
> second is called.
> 
> BTW, I now realized that the following causes a SystemError:
> _overlapped.Overlapped().ConnectEx(1, 2)
> should i fix this as part of this issue? (I thought about adding a call to
> PyTuple_CheckExact before the first call to PyArg_ParseTuple.)
> or should i open a new issue for that?

This looks as a part of this issue to me. It can be fixed by using "O!" instead
of "O" in Overlapped_ConnectEx().
Sign in to reply to this message.

RSS Feeds Recent Issues | This issue
This is Rietveld 894c83f36cb7+