public inbox for fstests@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] common/rc: move rm out from if block to always delete kmemleak temp file
@ 2018-04-23  5:23 Misono Tomohiro
  2018-04-23  5:40 ` Darrick J. Wong
  0 siblings, 1 reply; 2+ messages in thread
From: Misono Tomohiro @ 2018-04-23  5:23 UTC (permalink / raw)
  To: fstests

Otherwise, *.kmemleak.tmp may remain in result folder if kmemleak is on.

Signed-off-by: Tomohiro Misono <misono.tomohiro@jp.fujitsu.com>
---
 common/rc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/common/rc b/common/rc
index 366489bb..0c3359fd 100644
--- a/common/rc
+++ b/common/rc
@@ -3515,8 +3515,8 @@ EXPERIMENTAL kmemleak reported some memory leaks!  Due to the way kmemleak
 works, the leak might be from an earlier test, or something totally unrelated.
 ENDL
 		cat "$leak_file.tmp" >> "$leak_file"
-		rm -rf "$leak_file.tmp"
 	fi
+	rm -rf "$leak_file.tmp"
 	echo "clear" > "$kern_knob"
 }
 
-- 
2.14.3


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-04-23  5:40 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-04-23  5:23 [PATCH] common/rc: move rm out from if block to always delete kmemleak temp file Misono Tomohiro
2018-04-23  5:40 ` Darrick J. Wong

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox