Repository navigation
util: do not retry close after EINTR - #461
Open
tokenjunkielabs wants to merge 2 commits into
Open
tokenjunkielabs wants to merge 2 commits into
tokenjunkielabs wants to merge 2 commits into
Conversation
Author
|
Maintainer review requested. The PR changes only cleanup handling of |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #460.
Stop retrying
close()afterEINTRin two cleanup paths:/dev/urandomteardown inentropy_read_done();ipc_sync_close()helper.On systems where the descriptor has already been released before
EINTRis returned, retrying can close a descriptor which another thread has since acquired. The patch treatsEINTRas non-retry cleanup and preserves error reporting for every other failure.Reporter / bounty claimant: @woahwhattheheck
Exact source head:
1e576fd56f78a6aed950c6160a7d71ef76cd2b0dAI disclosure (per AGENTS.md): This PR was prepared with LLM assistance acting on behalf of Bryce / @woahwhattheheck through @tokenjunkielabs. Bryce is available to discuss the finding and revise the patch in response to maintainer review.