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

Use CancelIoEx instead of CancelIo on windows_native #152

Merged
merged 1 commit into from
Mar 2, 2024

Commits on Feb 23, 2024

  1. Use CancelIoEx instead of CancelIo on windows_native

    Fixes a use-after-free bug when dropping the HidDevice from a thread
    other than the one that was last used to read it, because of a pending
    async operation that did not get canceled.
    
    If the cancellation does not return an error, we get the overlapped
    result to block until it actually goes through. This is recommended by
    Microsoft in this example:
    <https://learn.microsoft.com/en-us/windows/win32/fileio/canceling-pending-i-o-operations#canceling-asynchronous-io>.
    
    Closes ruabmbua#151
    YgorSouza committed Feb 23, 2024
    Configuration menu
    Copy the full SHA
    884544d View commit details
    Browse the repository at this point in the history