8000 Fixup recursive locking · python/cpython@90bea6a · GitHub
[go: up one dir, main page]

Skip to content

Commit 90bea6a

Browse files
committed
Fixup recursive locking
1 parent 7407ce9 commit 90bea6a

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

Objects/dictobject.c

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1342,10 +1342,8 @@ insert_split_dict(PyInterpreterState *interp, PyDictObject *mp,
13421342
LOCK_KEYS(keys);
13431343
if (keys->dk_usable <= 0) {
13441344
/* Need to resize. */
1345-
dictkeys_incref(keys);
1346-
int ins = insertion_resize(interp, mp, 1);
1347-
dictkeys_decref(interp, keys);
13481345
UNLOCK_KEYS(keys);
1346+
int ins = insertion_resize(interp, mp, 1);
13491347
if (ins < 0) {
13501348
return -1;
13511349
}
@@ -3997,8 +3995,6 @@ dict_popitem_impl(PyDictObject *self)
39973995
}
39983996
/* Convert split table to combined table */
39993997
if (_PyDict_HasSplitTable(self)) {
4000-
PyDictKeysObject *keys = self->ma_keys;
4001-
40023998
if (dictresize(interp, self, DK_LOG_SIZE(self->ma_keys), 1) < 0) {
40033999
Py_DECREF(res);
40044000
return NULL;

0 commit comments

Comments
 (0)
0