mirror of
https://github.com/opencontainers/runc.git
synced 2026-07-11 06:03:57 +08:00
libct/int: waitProcess: rm dead code
Since Wait returns an ExitError if process' exit status is not 0,
checking process status is redundant and this code is never reached.
Remove it.
Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
(cherry picked from commit dd9fda7d60)
Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
This commit is contained in:
@@ -88,14 +88,10 @@ func ok(t testing.TB, err error) {
|
||||
|
||||
func waitProcess(p *libcontainer.Process, t testing.TB) {
|
||||
t.Helper()
|
||||
status, err := p.Wait()
|
||||
_, err := p.Wait()
|
||||
if err != nil {
|
||||
t.Fatalf("unexpected error: %v", err)
|
||||
}
|
||||
|
||||
if !status.Success() {
|
||||
t.Fatalf("unexpected status: %v", status)
|
||||
}
|
||||
}
|
||||
|
||||
// newRootfs creates a new tmp directory and copies the busybox root
|
||||
|
||||
Reference in New Issue
Block a user