diff --git a/drivers/rust/driver/src/child_process.rs b/drivers/rust/driver/src/child_process.rs index cdea420e..326562cd 100644 --- a/drivers/rust/driver/src/child_process.rs +++ b/drivers/rust/driver/src/child_process.rs @@ -115,7 +115,10 @@ impl ChildPluginProcess { let mut s = System::new(); s.refresh_processes(); if let Some(process) = s.process(Pid::from_u32(self.child_pid as u32)) { + #[cfg(not(windows))] process.kill(); + #[cfg(windows)] + process::Command::new("taskkill.exe").arg("/PID").arg(child_pid.to_string()).arg("/F").arg("/T").output(); } else { warn!("Child process with PID {} was not found", self.child_pid); } diff --git a/drivers/rust/driver/src/plugin_manager.rs b/drivers/rust/driver/src/plugin_manager.rs index fff966d7..091f6e55 100644 --- a/drivers/rust/driver/src/plugin_manager.rs +++ b/drivers/rust/driver/src/plugin_manager.rs @@ -284,7 +284,10 @@ async fn start_plugin_process(manifest: &PactPluginManifest) -> anyhow::Result