diff --git a/utils_linux.go b/utils_linux.go index 0cac09f5924..ea8b8ebf44c 100644 --- a/utils_linux.go +++ b/utils_linux.go @@ -43,9 +43,8 @@ func getDefaultImagePath() string { return filepath.Join(cwd, "checkpoint") } -// newProcess returns a new libcontainer Process with the arguments from the -// spec and stdio from the current process. -func newProcess(p specs.Process) (*libcontainer.Process, error) { +// newProcess converts [specs.Process] to [libcontainer.Process]. +func newProcess(p *specs.Process) (*libcontainer.Process, error) { lp := &libcontainer.Process{ Args: p.Args, Env: p.Env, @@ -218,7 +217,7 @@ func (r *runner) run(config *specs.Process) (int, error) { if err = r.checkTerminal(config); err != nil { return -1, err } - process, err := newProcess(*config) + process, err := newProcess(config) if err != nil { return -1, err }