diff options
author | Victor Stinner <victor.stinner@haypocalc.com> | 2010-09-29 17:55:12 (GMT) |
---|---|---|
committer | Victor Stinner <victor.stinner@haypocalc.com> | 2010-09-29 17:55:12 (GMT) |
commit | 71e91a358ba0b99319fb6553016094925937e031 (patch) | |
tree | 730e4273e242822e75155358eca40a6ef1fc032f /Objects | |
parent | 15d597a2454e5070cec2ebfe072480ed8f01d720 (diff) | |
download | cpython-71e91a358ba0b99319fb6553016094925937e031.zip cpython-71e91a358ba0b99319fb6553016094925937e031.tar.gz cpython-71e91a358ba0b99319fb6553016094925937e031.tar.bz2 |
Fix PyUnicode_AsWideCharString(): set *size if size is not NULL
Diffstat (limited to 'Objects')
-rw-r--r-- | Objects/unicodeobject.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Objects/unicodeobject.c b/Objects/unicodeobject.c index 8ceb3f3..29404c3 100644 --- a/Objects/unicodeobject.c +++ b/Objects/unicodeobject.c @@ -1215,6 +1215,8 @@ PyUnicode_AsWideCharString(PyUnicodeObject *unicode, return NULL; } unicode_aswidechar(unicode, buffer, buflen); + if (size) + *size = buflen; return buffer; } |