Skip to content

[3.13] gh-123321: Make Parser/myreadline.c locking safe in free-threaded build (GH-123690)#123798

Merged
Yhg1s merged 1 commit intopython:3.13from
miss-islington:backport-0c080d7-3.13
Sep 6, 2024
Merged

[3.13] gh-123321: Make Parser/myreadline.c locking safe in free-threaded build (GH-123690)#123798
Yhg1s merged 1 commit intopython:3.13from
miss-islington:backport-0c080d7-3.13

Conversation

@miss-islington
Copy link
Contributor

@miss-islington miss-islington commented Sep 6, 2024

Use a PyMutex to avoid the race in mutex initialization. Use relaxed
atomics to avoid the data race on reading _PyOS_ReadlineTState when
checking for re-entrant calls.
(cherry picked from commit 0c080d7)

Co-authored-by: Sam Gross colesbury@gmail.com

…ed build (pythonGH-123690)

Use a `PyMutex` to avoid the race in mutex initialization. Use relaxed
atomics to avoid the data race on reading `_PyOS_ReadlineTState` when
checking for re-entrant calls.
(cherry picked from commit 0c080d7)

Co-authored-by: Sam Gross <colesbury@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants