[issue6373] SystemError in encoder

2009-06-29 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: Fixed with r73698 (py3k) and r73699. -- resolution: -> fixed status: open -> closed ___ Python tracker ___ __

[issue6373] SystemError in encoder

2009-06-29 Thread Benjamin Peterson
Benjamin Peterson added the comment: The patch looks good. -- nosy: +benjamin.peterson ___ Python tracker ___ ___ Python-bugs-list mai

[issue6373] SystemError in encoder

2009-06-29 Thread Jerry Chen
Jerry Chen added the comment: Confirmed patch and test are working -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubsc

[issue6373] SystemError in encoder

2009-06-29 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: It's a bug in unicode_encode_ucs1: the result string is resized, so str = PyBytes_AS_STRING(res) + (someOffset) is not valid anymore. Attached patch+test. -- keywords: +patch nosy: +amaury.forgeotdarc Added file: http://bugs.python.org/file14

[issue6373] SystemError in encoder

2009-06-29 Thread R. David Murray
Changes by R. David Murray : -- nosy: +loewis priority: -> normal ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe

[issue6373] SystemError in encoder

2009-06-29 Thread Jerry Chen
Jerry Chen added the comment: gdb trace Breakpoint 1, _PyBytes_Resize (pv=0xbfffec3c, newsize=-495723) at Objects/bytesobject.c:3179 3179if (!PyBytes_Check(v) || Py_REFCNT(v) != 1 || newsize < 0) { (gdb) where #0 _PyBytes_Resize (pv=0xbfffec3c, newsize=-495723) at Objects/bytesobje

[issue6373] SystemError in encoder

2009-06-29 Thread Glynn Clements
New submission from Glynn Clements : Test case: > "\udce4\udceb\udcef\udcf6\udcfc".encode("iso-8859-1", "surrogateescape") Traceback (most recent call last): File "", line 1, in SystemError: Objects/bytesobject.c:3182: bad argument to internal function The line number corresponds to _PyBytes