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

Make DeviceLostClosure.from_c mutate the closure before dropping it. #5032

Merged
merged 2 commits into from
Jan 14, 2024

Commits on Jan 12, 2024

  1. Make DeviceLostClosure.from_c consume the closure before dropping it.

    This clarifies that the Rust and C-style callbacks/closures need to be
    consumed (not called) before they are dropped. It also makes the from_c
    function consume the param closure so that it can be dropped without
    panicking.
    
    It also relaxes the restriction that the callback/closure can only be
    called once.
    bradwerth committed Jan 12, 2024
    Configuration menu
    Copy the full SHA
    4e16f37 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    011e03f View commit details
    Browse the repository at this point in the history