diff options
| author | Can Celik <ogulcancelik@gmail.com> | 2026-09-15 21:37:49 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-09-15 21:37:49 +0300 |
| commit | 266b8e3802e22cd0da6eb5f24b269278c80d1bf4 (patch) | |
| tree | 699ad092f6bdaed60e1ea35033fe3ed130c7165c /src/platform/mod.rs | |
| parent | 4428e1664d8d897ce2f914777c0fe060cf334c84 (diff) | |
fix: preserve macos services across logout (#4202)
refs #4100
Diffstat (limited to 'src/platform/mod.rs')
| -rw-r--r-- | src/platform/mod.rs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/platform/mod.rs b/src/platform/mod.rs index 70047fef..eb84e0b1 100644 --- a/src/platform/mod.rs +++ b/src/platform/mod.rs @@ -153,10 +153,18 @@ pub fn launch_server_daemon_command(command: &mut std::process::Command) -> std: command.spawn().map(|child| child.id()) } +#[cfg(not(target_os = "macos"))] +pub(crate) fn prepare_server_process(_handoff_import: bool) -> std::io::Result<bool> { + Ok(false) +} + #[cfg(any(target_os = "linux", target_os = "macos"))] pub fn detach_server_daemon_command(command: &mut std::process::Command) { use std::os::unix::process::CommandExt; + #[cfg(target_os = "macos")] + macos::configure_server_daemon_context(command); + unsafe { command.pre_exec(|| { if libc::setsid() < 0 { |
