diff options
author | Benjamin Peterson <benjamin@python.org> | 2015-03-02 18:23:41 (GMT) |
---|---|---|
committer | Benjamin Peterson <benjamin@python.org> | 2015-03-02 18:23:41 (GMT) |
commit | 92ce1b4392a533a14bbebb8e60bf79bf4bf4c6c7 (patch) | |
tree | 40c3d3edc63654c4492c2716d9ae29ef815ad5d9 | |
parent | 5061e67f0f6e08e99b2ca3b560cd64d8cc5aa515 (diff) | |
parent | e5a853c390f76f8d73939138adf70604fe33ca4c (diff) | |
download | cpython-92ce1b4392a533a14bbebb8e60bf79bf4bf4c6c7.zip cpython-92ce1b4392a533a14bbebb8e60bf79bf4bf4c6c7.tar.gz cpython-92ce1b4392a533a14bbebb8e60bf79bf4bf4c6c7.tar.bz2 |
merge 3.3 (#23362)
-rw-r--r-- | Objects/unicodeobject.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Objects/unicodeobject.c b/Objects/unicodeobject.c index d8f1ce1..42cda58 100644 --- a/Objects/unicodeobject.c +++ b/Objects/unicodeobject.c @@ -8665,7 +8665,7 @@ _PyUnicode_TranslateCharmap(PyObject *input, /* allocate enough for a simple 1:1 translation without replacements, if we need more, we'll resize */ osize = size; - output = PyMem_Malloc(osize * sizeof(Py_UCS4)); + output = PyMem_NEW(Py_UCS4, osize); opos = 0; if (output == NULL) { PyErr_NoMemory(); |