[New-bugs-announce] [issue23321] Crash in str.decode() with special error handler

Serhiy Storchaka report at bugs.python.org
Mon Jan 26 00:16:13 CET 2015

New submission from Serhiy Storchaka:

Debugging build crashes in some circumstances in str.decode() with error handler which produces replacement string with length larger than malformed data. For example the backslashreplace error handler produces 4-character string for every illegal byte. All other standard error handlers produce no longer than 1 character for every illegal unit.

Here is a patch which fixes this issue. I'll commit it without review because buildbots are broken without it. This issue is open for reference and post-commit review.

assignee: serhiy.storchaka
components: Interpreter Core
files: unicode_decode_call_errorhandler_writer.patch
keywords: patch
messages: 234705
nosy: haypo, serhiy.storchaka
priority: normal
severity: normal
stage: patch review
status: open
title: Crash in str.decode() with special error handler
type: crash
versions: Python 3.4, Python 3.5
Added file: http://bugs.python.org/file37861/unicode_decode_call_errorhandler_writer.patch

Python tracker <report at bugs.python.org>

More information about the New-bugs-announce mailing list