diff options
author | Victor Stinner <victor.stinner@gmail.com> | 2016-04-26 10:35:13 (GMT) |
---|---|---|
committer | Victor Stinner <victor.stinner@gmail.com> | 2016-04-26 10:35:13 (GMT) |
commit | 71dc3d878a44c8fc6b9b1743750600d4902538f2 (patch) | |
tree | 56f833cea9ced7d83d9a20544d074c91375c06b2 /Objects/bytesobject.c | |
parent | 45009778aa131b99bc95412390dae232d9f760a7 (diff) | |
download | cpython-71dc3d878a44c8fc6b9b1743750600d4902538f2.zip cpython-71dc3d878a44c8fc6b9b1743750600d4902538f2.tar.gz cpython-71dc3d878a44c8fc6b9b1743750600d4902538f2.tar.bz2 |
Issue #25349, #26249: Fix memleak in formatfloat()
Diffstat (limited to 'Objects/bytesobject.c')
-rw-r--r-- | Objects/bytesobject.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Objects/bytesobject.c b/Objects/bytesobject.c index 701ae9d..296c73b 100644 --- a/Objects/bytesobject.c +++ b/Objects/bytesobject.c @@ -438,6 +438,7 @@ formatfloat(PyObject *v, int flags, int prec, int type, if (str == NULL) return NULL; Py_MEMCPY(str, p, len); + PyMem_Free(p); str += len; return str; } |