Skip to content

Commit

Permalink
Merge Windows dependencies and fix for new Windows HMODULE API
Browse files Browse the repository at this point in the history
  • Loading branch information
novafacing committed Dec 6, 2024
1 parent ce9fe5d commit c6eae66
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 12 deletions.
17 changes: 6 additions & 11 deletions qemu-plugin/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,21 +18,16 @@ qemu-plugin-sys = { version = "9.1.2-v0", workspace = true, default-features = f
thiserror = "2.0.4"
num-traits = { version = "0.2.19", optional = true }

[target.'cfg(windows)'.dependencies.libloading]
version = "0.8.6"
[target.'cfg(windows)'.dependencies.lazy_static]
version = "1.5.0"

[target.'cfg(windows)'.dependencies.windows]
version = "0.58.0"
features = [
[target.'cfg(windows)'.dependencies]
windows = { version = "0.58.0", features = [
"Win32_System_WindowsProgramming",
"Win32_System_LibraryLoader",
"Win32_Foundation",
]
] }

[target.'cfg(windows)'.dependencies.libc]
version = "0.2.167"
libloading = "0.8.6"
lazy_static = "1.5.0"
libc = "0.2.167"

[features]
default = ["plugin-api-v4"]
Expand Down
2 changes: 1 addition & 1 deletion qemu-plugin/src/win_link_hook/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ extern "C" fn delaylink_hook(dli_notify: DliNotify, pdli: DELAYLOAD_INFO) -> HMO
return HMODULE(
libloading::os::windows::Library::this()
.expect("Get QEMU module")
.into_raw(),
.into_raw() as *mut _,
);
}
}
Expand Down

0 comments on commit c6eae66

Please sign in to comment.