helper/bwrap: merge Args and FDArgs
All checks were successful
Test / Create distribution (push) Successful in 1m13s
Test / Run NixOS test (push) Successful in 4m34s

Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
2025-02-14 18:13:06 +09:00
parent 73146ea7fa
commit ace97952cc
4 changed files with 33 additions and 48 deletions

View File

@@ -155,9 +155,8 @@ func bwrapStub() {
DieWithParent: true,
AsInit: true,
}
args := sc.Args()
sc.FDArgs(nil, &args, new(proc.ExtraFilesPre), new([]proc.File))
if _, err := MustNewCheckedArgs(args).WriteTo(want); err != nil {
if _, err := MustNewCheckedArgs(sc.Args(nil, new(proc.ExtraFilesPre), new([]proc.File))).
WriteTo(want); err != nil {
panic("cannot read want: " + err.Error())
}