mirror of
https://github.com/edera-dev/krata.git
synced 2025-08-03 05:10:55 +00:00
container: fix bug where argv[0] was not set properly
This commit is contained in:
parent
6511f2f0fa
commit
b30c785817
@ -380,7 +380,10 @@ impl ContainerInit {
|
|||||||
cmd.push("/bin/sh".to_string());
|
cmd.push("/bin/sh".to_string());
|
||||||
}
|
}
|
||||||
|
|
||||||
let path = cmd.remove(0);
|
let path = cmd
|
||||||
|
.first()
|
||||||
|
.ok_or_else(|| anyhow!("command is empty"))?
|
||||||
|
.clone();
|
||||||
let mut env = match config.env() {
|
let mut env = match config.env() {
|
||||||
None => vec![],
|
None => vec![],
|
||||||
Some(value) => value.clone(),
|
Some(value) => value.clone(),
|
||||||
|
Loading…
Reference in New Issue
Block a user