From 35a8e6e589eb37a73f94cdbd5c8d7938b2b04140 Mon Sep 17 00:00:00 2001 From: Shengjing Zhu Date: Wed, 15 Jan 2020 18:13:49 +0800 Subject: [PATCH] sys: clean up process after test Signed-off-by: Shengjing Zhu --- sys/oom_unix_test.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sys/oom_unix_test.go b/sys/oom_unix_test.go index 2e399b52f..f849c64ec 100644 --- a/sys/oom_unix_test.go +++ b/sys/oom_unix_test.go @@ -72,6 +72,8 @@ func adjustOom(adjustment int) (int, error) { return 0, err } + defer cmd.Process.Kill() + pid, err := waitForPid(cmd.Process) if err != nil { return 0, err