Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions src-tauri/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -115,10 +115,11 @@ pub fn run() {
// Kill sidecar when the app window is closed
if let tauri::WindowEvent::Destroyed = event {
let state = window.state::<SidecarState>();
if let Some(child) = state.child.lock().unwrap().take() {
let child = state.child.lock().unwrap().take();
if let Some(child) = child {
let _ = child.kill();
eprintln!("[sidecar] Process killed on window close");
}
};
}
})
.run(tauri::generate_context!())
Expand Down
Loading