Issue 28715: Check result of PyUnicode_AsUTF8 (original) (raw)
This issue has been migrated to GitHub: https://github.com/python/cpython/issues/72901
classification
Title: | Check result of PyUnicode_AsUTF8 | ||
---|---|---|---|
Type: | crash | Stage: | resolved |
Components: | Extension Modules, Interpreter Core | Versions: | Python 3.7, Python 3.6, Python 3.5 |
process
Status: | closed | Resolution: | fixed |
---|---|---|---|
Dependencies: | Superseder: | ||
Assigned To: | serhiy.storchaka | Nosy List: | python-dev, serhiy.storchaka |
Priority: | normal | Keywords: | patch |
Created on 2016-11-16 17:46 by serhiy.storchaka, last changed 2022-04-11 14:58 by admin. This issue is now closed.
Files | |||
---|---|---|---|
File name | Uploaded | Description | Edit |
check-PyUnicode_AsUTF8.patch | serhiy.storchaka,2016-11-16 17:46 | review |
Messages (3) | ||
---|---|---|
msg280972 - (view) | Author: Serhiy Storchaka (serhiy.storchaka) * ![]() |
Date: 2016-11-16 17:46 |
The function PyUnicode_AsUTF8() can fail, but not all callers check for error. Proposed patch adds missed checks. In some places the code is rewritten to not use PyUnicode_AsUTF8() at all. | ||
msg280982 - (view) | Author: Serhiy Storchaka (serhiy.storchaka) * ![]() |
Date: 2016-11-16 19:57 |
_PyUnicode_AsString is just an outdated alias to PyUnicode_AsUTF8. | ||
msg281252 - (view) | Author: Roundup Robot (python-dev) ![]() |
Date: 2016-11-20 06:48 |
New changeset 38f321a6be41 by Serhiy Storchaka in branch '3.5': Issue #28715: Added error checks for PyUnicode_AsUTF8(). https://hg.python.org/cpython/rev/38f321a6be41 New changeset 0bb8ab158042 by Serhiy Storchaka in branch '3.6': Issue #28715: Added error checks for PyUnicode_AsUTF8(). https://hg.python.org/cpython/rev/0bb8ab158042 New changeset 9cd42ed64bdb by Serhiy Storchaka in branch 'default': Issue #28715: Added error checks for PyUnicode_AsUTF8(). https://hg.python.org/cpython/rev/9cd42ed64bdb |
History | |||
---|---|---|---|
Date | User | Action | Args |
2022-04-11 14:58:39 | admin | set | github: 72901 |
2016-11-20 06:49:12 | serhiy.storchaka | set | status: open -> closedresolution: fixedstage: patch review -> resolved |
2016-11-20 06:48:49 | python-dev | set | nosy: + python-devmessages: + |
2016-11-20 06:47:32 | serhiy.storchaka | set | assignee: serhiy.storchaka |
2016-11-16 19:57:55 | serhiy.storchaka | set | messages: + |
2016-11-16 17:46:27 | serhiy.storchaka | create |