summaryrefslogtreecommitdiffstats
path: root/Modules/_testcapi/code.c
diff options
context:
space:
mode:
Diffstat (limited to 'Modules/_testcapi/code.c')
-rw-r--r--Modules/_testcapi/code.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/_testcapi/code.c b/Modules/_testcapi/code.c
index 84c668c..cadaf5e 100644
--- a/Modules/_testcapi/code.c
+++ b/Modules/_testcapi/code.c
@@ -9,7 +9,7 @@ get_code_extra_index(PyInterpreterState* interp) {
PyObject *interp_dict = PyInterpreterState_GetDict(interp); // borrowed
assert(interp_dict); // real users would handle missing dict... somehow
- PyObject *index_obj = PyDict_GetItemString(interp_dict, key); // borrowed
+ PyObject *index_obj = _PyDict_GetItemStringWithError(interp_dict, key); // borrowed
Py_ssize_t index = 0;
if (!index_obj) {
if (PyErr_Occurred()) {