feat(installer): add dummy command to prevent empty shell execution
The change adds `arg("true")` to the shell command to prevent executing an empty shell command when a component is already running. This ensures a valid command is always passed to the shell, avoiding potential issues with empty command execution.
This commit is contained in:
parent
4b76243662
commit
a9af37e385
1 changed files with 1 additions and 1 deletions
|
|
@ -674,7 +674,7 @@ impl PackageManager {
|
||||||
|
|
||||||
if check_status.is_ok() && check_status.unwrap().success() {
|
if check_status.is_ok() && check_status.unwrap().success() {
|
||||||
trace!("Component {} is already running", component.name);
|
trace!("Component {} is already running", component.name);
|
||||||
return Ok(std::process::Command::new("sh").arg("-c").spawn()?);
|
return Ok(std::process::Command::new("sh").arg("-c").arg("true").spawn()?);
|
||||||
}
|
}
|
||||||
|
|
||||||
// If not running, execute the main command
|
// If not running, execute the main command
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue