diff options
author | Victor Stinner <vstinner@redhat.com> | 2019-03-14 16:19:52 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-03-14 16:19:52 (GMT) |
commit | b14057877fd897eaee7bc6626682fc6092b6bbd2 (patch) | |
tree | b0e75922f1a071ecb92b44ec8257b051e1c7f54a /Python/formatter_unicode.c | |
parent | 2dd6e079ae71f3723fbea2582ac080be06a6968f (diff) | |
download | cpython-b14057877fd897eaee7bc6626682fc6092b6bbd2.zip cpython-b14057877fd897eaee7bc6626682fc6092b6bbd2.tar.gz cpython-b14057877fd897eaee7bc6626682fc6092b6bbd2.tar.bz2 |
bpo-36262: Fix _Py_dg_strtod() memory leak (goto undfl) (GH-12276) (GH-12332)
Fix an unlikely memory leak on conversion from string to float in the
function _Py_dg_strtod() used by float(str), complex(str),
pickle.load(), marshal.load(), etc.
Fix an unlikely memory leak in _Py_dg_strtod() on "undfl:" label:
rewrite memory management in this function to always release all
memory before exiting the function. Initialize variables to NULL, and
set them to NULL after calling Bfree() at the "cont:" label.
Note: Bfree(NULL) is well defined: it does nothing.
(cherry picked from commit 9776b0636ae39668d3ce1c006d4be01dad01bf9f)
Diffstat (limited to 'Python/formatter_unicode.c')
0 files changed, 0 insertions, 0 deletions