Stop --chdir from binding the working directory read-write
This commit is contained in:
@@ -171,9 +171,10 @@ fn interrupt_during_grace_period_kills_child_processes_at_once() {
|
||||
}
|
||||
|
||||
fn spawn_sandbox(args: &[&str], dir: &Path, script: &str) -> (Sandbox, Child) {
|
||||
let dir = dir.to_str().unwrap();
|
||||
let mut sandbox = Sandbox::new(args);
|
||||
let child = sandbox
|
||||
.args(["--chdir", dir.to_str().unwrap(), "--", "sh", "-c", script])
|
||||
.args(["--rw", dir, "--chdir", dir, "--", "sh", "-c", script])
|
||||
.stdout(Stdio::null())
|
||||
.spawn()
|
||||
.expect("agent-sandbox binary failed to execute");
|
||||
|
||||
Reference in New Issue
Block a user