Skip to content

[3.6] closes bpo-32859: Don't retry dup3() if it is not available at runtime (GH-5708)#5769

Merged
benjaminp merged 1 commit into
python:3.6from
miss-islington:backport-b3caf38-3.6
Feb 21, 2018
Merged

[3.6] closes bpo-32859: Don't retry dup3() if it is not available at runtime (GH-5708)#5769
benjaminp merged 1 commit into
python:3.6from
miss-islington:backport-b3caf38-3.6

Conversation

@miss-islington

@miss-islington miss-islington commented Feb 20, 2018

Copy link
Copy Markdown
Contributor

os.dup2() tests for dup3() system call availability at runtime,
but doesn't remember the result across calls, repeating
the test on each call with inheritable=False.

Since the caller of os.dup2() is expected to hold the GIL,
fix this by making the variable holding the test result static.
(cherry picked from commit b3caf38)

Co-authored-by: Alexey Izbyshev izbyshev@users.noreply.github.com

https://bugs.python.org/issue32859

pythonGH-5708)

os.dup2() tests for dup3() system call availability at runtime,
but doesn't remember the result across calls, repeating
the test on each call with inheritable=False.

Since the caller of os.dup2() is expected to hold the GIL,
fix this by making the variable holding the test result static.
(cherry picked from commit b3caf38)

Co-authored-by: Alexey Izbyshev <izbyshev@users.noreply.github.com>
@miss-islington

Copy link
Copy Markdown
Contributor Author

@izbyshev and @benjaminp: Backport status check is done, and it's a success ✅ .

@benjaminp benjaminp merged commit 16de2a9 into python:3.6 Feb 21, 2018
@miss-islington

Copy link
Copy Markdown
Contributor Author

Thanks, @benjaminp!

@miss-islington miss-islington deleted the backport-b3caf38-3.6 branch February 21, 2018 05:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants