[New-bugs-announce] [issue1098] decode_unicode doesn't nul-terminate

Adam Olsen report at bugs.python.org
Tue Sep 4 07:38:55 CEST 2007

New submission from Adam Olsen:

In the large else branch in decode_unicode (if encoding is not NULL or
"iso-8859-1"), the new string it produces is not nul-terminated.  This
then hits PyUnicode_DecodeUnicodeEscape's octal escape case, which reads
past the end of the string (but would stop if there was a nul there.)

I found this via valgrind.

messages: 55630
nosy: rhamphoryncus
severity: normal
status: open
title: decode_unicode doesn't nul-terminate

Tracker <report at bugs.python.org>

More information about the New-bugs-announce mailing list