forked from rust-vmm/vhost-device
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
sound: Put AlsaTestHarness static in a LazyLock
Instead of using unsafe {} and undefined behavior (mutable shared static references) use LazyLock which initializes the harness on first dereference and provides immutable access only (the harness type has interior mutability). Fixes: rust-vmm#785 Signed-off-by: Manos Pitsidianakis <[email protected]>
- Loading branch information
Showing
1 changed file
with
22 additions
and
84 deletions.
There are no files selected for viewing
This file contains 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