From: Sean Reifscheider Date: Sat, 1 Aug 2009 23:54:55 +0000 (+0000) Subject: - Issue #6624: yArg_ParseTuple with "s" format when parsing argument with X-Git-Tag: v2.7a1~687 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9279e7d1771a03a2e494b03d82bad2fde8b8f1aa;p=thirdparty%2FPython%2Fcpython.git - Issue #6624: yArg_ParseTuple with "s" format when parsing argument with NUL: Bogus TypeError detail string. --- diff --git a/Misc/NEWS b/Misc/NEWS index 37ccbeb40608..ad998b4962aa 100644 --- a/Misc/NEWS +++ b/Misc/NEWS @@ -1180,6 +1180,9 @@ Build C-API ----- +- Issue #6624: yArg_ParseTuple with "s" format when parsing argument with + NUL: Bogus TypeError detail string. + - Issue #5954: Add a PyFrame_GetLineNumber() function to replace most uses of PyCode_Addr2Line(). diff --git a/Python/getargs.c b/Python/getargs.c index d24857d29ccc..1fd17d3ddc11 100644 --- a/Python/getargs.c +++ b/Python/getargs.c @@ -328,7 +328,7 @@ vgetargs1(PyObject *args, const char *format, va_list *p_va, int flags) flags, levels, msgbuf, sizeof(msgbuf), &freelist); if (msg) { - seterror(i+1, msg, levels, fname, message); + seterror(i+1, msg, levels, fname, msg); return cleanreturn(0, freelist); } }