[New-bugs-announce] [issue28408] Fix redundant code and memory leak in _PyUnicodeWriter_Finish
Xiang Zhang
report at bugs.python.org
Mon Oct 10 13:13:36 EDT 2016
New submission from Xiang Zhang:
_PyUnicodeWriter_Finish gets 2 problems now:
1. It has two same branches handling empty strings which is redundant.
2. It may leak the inner buffer object when resize_compact fails. When resize_compact fails, the buffer object is left untouched. Then the writer itself is freed and the buffer is leaked.
----------
components: Interpreter Core
files: _PyUnicodeWriter_Finish.patch
keywords: patch
messages: 278434
nosy: haypo, serhiy.storchaka, xiang.zhang
priority: normal
severity: normal
stage: patch review
status: open
title: Fix redundant code and memory leak in _PyUnicodeWriter_Finish
type: behavior
versions: Python 3.5, Python 3.6, Python 3.7
Added file: http://bugs.python.org/file45048/_PyUnicodeWriter_Finish.patch
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue28408>
_______________________________________
More information about the New-bugs-announce
mailing list