fix(monado): stop monado.service cleanly on engine shutdown to prevent window hang

This commit is contained in:
bleackstorm committed 2026-11-06 23:55:56 +01:00
1 parent 378332b892
commit b7ef8b10a4
1 file changed
+9
+9
View File
@@ -176,6 +176,15 @@ impl FpvEngineController {
log::info!("[Moteur FPV] Arrêt et jonction du thread worker...");
let _ = handle.join();
}
// Sur Linux, s'assurer que la fenêtre de simulation de Monado ne reste pas bloquée
#[cfg(target_os = "linux")]
{
let _ = std::process::Command::new("systemctl")
.args(["--user", "stop", "monado.service"])
.output();
}
let mut mon = self.monitor.lock();
mon.usb_video_status = SubsystemStatus::Stopped;
mon.openxr_status = SubsystemStatus::Stopped;