From f263e48feaefe460cbf705346b5e56313d4a9250 Mon Sep 17 00:00:00 2001 From: Diggory Blake Date: Wed, 28 Jun 2023 16:49:02 +0100 Subject: [PATCH] Suppress the console popup on windows --- src/browser/process.rs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/browser/process.rs b/src/browser/process.rs index dfff8600..cf63d41e 100644 --- a/src/browser/process.rs +++ b/src/browser/process.rs @@ -397,6 +397,14 @@ impl Process { command.envs(process_envs); } + // Suppress creation of a console window on windows + #[cfg(windows)] + { + use std::os::windows::process::CommandExt; + const CREATE_NO_WINDOW: u32 = 0x08000000; + command.creation_flags(CREATE_NO_WINDOW); + } + let process = TemporaryProcess( command.args(&args).stderr(Stdio::piped()).spawn()?, temp_user_data_dir,