Skip to content

Commit

Permalink
pythongh-117657: Fix data race in dict_dict_merge (pythongh-129755)
Browse files Browse the repository at this point in the history
Found while running `test_load_attr_module` from `test_opcache` under TSan.
  • Loading branch information
colesbury authored Feb 7, 2025
1 parent 1758447 commit 34379d0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Objects/dictobject.c
Original file line number Diff line number Diff line change
Expand Up @@ -3793,7 +3793,7 @@ dict_dict_merge(PyInterpreterState *interp, PyDictObject *mp, PyDictObject *othe

ensure_shared_on_resize(mp);
dictkeys_decref(interp, mp->ma_keys, IS_DICT_SHARED(mp));
mp->ma_keys = keys;
set_keys(mp, keys);
STORE_USED(mp, other->ma_used);
ASSERT_CONSISTENT(mp);

Expand Down

0 comments on commit 34379d0

Please sign in to comment.