Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

close all FDs in child faster(er) #149

Closed
wants to merge 1 commit into from

Conversation

bigfoot547
Copy link

This method uses the close_range(2) library function.

fixes #147

intended as a more portable replacement for #124

This method uses the close_range(2) library function
@mbiebl
Copy link

mbiebl commented Jun 11, 2024

I tested this MR and I can confirm that it fixes #147

@segrey
Copy link
Collaborator

segrey commented Jun 17, 2024

@bigfoot547 Thanks for the PR. Hopefully, I've improved it a bit in 04685d8. I'd appeciate if you could review it and let me know if something requires more attention. @mbiebl

@segrey segrey closed this Jun 17, 2024
@mbiebl
Copy link

mbiebl commented Jun 17, 2024

@segrey thanks for the update. I've successfully tested it on Linux / Debian Sid.
Support for older systems / other OSes makes the change more convoluted. I haven't tested all those alternative code paths.

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.

100% CPU when the _SC_OPEN_MAX is a big number
3 participants