We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4f2de54 commit 93f84adCopy full SHA for 93f84ad
Modules/_testcapi/dict.c
@@ -347,9 +347,13 @@ dict_pop(PyObject *self, PyObject *args)
347
assert(result == NULL);
348
return NULL;
349
}
350
- if (result == NULL) {
+ if (res == 0) {
351
+ assert(result == NULL);
352
result = Py_NewRef(Py_None);
353
354
+ else {
355
+ assert(result != NULL);
356
+ }
357
return Py_BuildValue("iN", res, result);
358
359
@@ -388,9 +392,13 @@ dict_popstring(PyObject *self, PyObject *args)
388
392
389
393
390
394
391
395
396
397
398
399
400
401
402
403
404
0 commit comments