Skip to content

Commit

Permalink
pythongh-118849: Fix "code will never be executed" warning in `dictob…
Browse files Browse the repository at this point in the history
…ject.c`
  • Loading branch information
sobolevn committed May 9, 2024
1 parent c3643a1 commit d02409a
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions Objects/dictobject.c
Original file line number Diff line number Diff line change
Expand Up @@ -5491,10 +5491,9 @@ dictiter_iternext_threadsafe(PyDictObject *d, PyObject *self,
Py_DECREF(d);
return -1;

int res;
try_locked:
Py_BEGIN_CRITICAL_SECTION(d);
res = dictiter_iternextitem_lock_held(d, self, out_key, out_value);
int res = dictiter_iternextitem_lock_held(d, self, out_key, out_value);
Py_END_CRITICAL_SECTION();
return res;
}
Expand Down

0 comments on commit d02409a

Please sign in to comment.