Browse Source
bpo-36262: Fix _Py_dg_strtod() memory leak (goto undfl) (GH-12276)
bpo-36262: Fix _Py_dg_strtod() memory leak (goto undfl) (GH-12276)
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.pull/12310/head
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 28 additions and 54 deletions
@ -0,0 +1,3 @@ |
|||
Fix an unlikely memory leak on conversion from string to float in the function |
|||
``_Py_dg_strtod()`` used by ``float(str)``, ``complex(str)``, |
|||
:func:`pickle.load`, :func:`marshal.load`, etc. |
|||
Write
Preview
Loading…
Cancel
Save
Reference in new issue