[Python-checkins] cpython (3.3): Issue #18561: Skip name in ctypes' _build_callargs() if name is NULL.
christian.heimes
python-checkins at python.org
Fri Jul 26 23:04:51 CEST 2013
http://hg.python.org/cpython/rev/57457028dd7a
changeset: 84848:57457028dd7a
branch: 3.3
parent: 84846:de7e4fd634fb
user: Christian Heimes <christian at cheimes.de>
date: Fri Jul 26 23:04:29 2013 +0200
summary:
Issue #18561: Skip name in ctypes' _build_callargs() if name is NULL.
CID 486199
files:
Misc/NEWS | 2 ++
Modules/_ctypes/_ctypes.c | 2 +-
2 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/Misc/NEWS b/Misc/NEWS
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -54,6 +54,8 @@
Library
-------
+- Issue #18561: Skip name in ctypes' _build_callargs() if name is NULL.
+
- Issue #18559: Fix NULL pointer dereference error in _pickle module
- Issue #18556: Check the return value of a PyUnicode_AsWideChar() call in
diff --git a/Modules/_ctypes/_ctypes.c b/Modules/_ctypes/_ctypes.c
--- a/Modules/_ctypes/_ctypes.c
+++ b/Modules/_ctypes/_ctypes.c
@@ -3453,7 +3453,7 @@
Py_INCREF(v);
return v;
}
- if (kwds && (v = PyDict_GetItem(kwds, name))) {
+ if (kwds && name && (v = PyDict_GetItem(kwds, name))) {
++*pindex;
Py_INCREF(v);
return v;
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list