debugger: Fix the terminal popping up when the Rust debugger starts on Windows (#35125)

This PR fixs a terminal popping up when debugging Rust on Windows.


Release Notes:

- N/A

---------

Co-authored-by: 张小白 <364772080@qq.com>
This commit is contained in:
devjasperwang 2025-07-28 22:44:22 +08:00 committed by GitHub
parent c2fc70eef7
commit 5e2da042ef
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -128,7 +128,7 @@ impl DapLocator for CargoLocator {
.chain(Some("--message-format=json".to_owned()))
.collect(),
);
let mut child = Command::new(program)
let mut child = util::command::new_smol_command(program)
.args(args)
.envs(build_config.env.iter().map(|(k, v)| (k.clone(), v.clone())))
.current_dir(cwd)