Repository navigation
Conversation
An error or zero-size completion removed its call before provider cleanup. A blocking status query could miss the call during cleanup and read E_PENDING instead of the work result. Keep the claimed call available to waiters during unlocked cleanup, exclude it from new work, then publish the status and remove the entry under the registry lock. Return the captured call result to existing waiters even if the block is reused. Exercise the race deterministically with a paused cleanup. Adapted from Jineggegg/VIctory e071177. Foxhound had no claimed flag: its first-completion guard was the done lock. This port brings the claimed flag in, so completing, cancelling and scheduled work all agree on which calls are still live.
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.
What this fixes
An error or zero-size completion removed its call before provider cleanup ran. A blocking status query (
XAsyncGetStatuswith wait) could miss the call during cleanup and readE_PENDINGinstead of the work result.This change:
E_ABORT), notE_PENDING.Testing
cargo check -p victory-hle --lib: clean (only pre-existing warnings elsewhere).cargo test -p victory-hle --lib xasync: 13 passed, 0 failed, including the newstatus_waits_for_cleanup_to_publish_the_resulttest.Origin
Adapted from Jineggegg/VIctory
e071177(round-1 item #3). Foxhound had noclaimedflag — its first-completion guard was thedonelock — so this port brings theclaimedflag in, and completing, cancelling and scheduled work now agree on which calls are still live.