From 1895ea4b424917e50a833a41546d4ad2c80324c2 Mon Sep 17 00:00:00 2001 From: Vladimir Zapolskiy Date: Fri, 10 Jul 2020 17:13:50 +0300 Subject: [PATCH] common/rc: fix false positives due to leaked mkfs output to stderr The change fixes false positives reported by a few generic tests under circumstances, when an mkfs utility prints its output to stderr and then it appears in produced *.out files. The change is intended to fix such issues in the tests, which utilize _require_scratch_swapfile(). Signed-off-by: Vladimir Zapolskiy Reviewed-by: Eryu Guan Signed-off-by: Eryu Guan --- common/rc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/rc b/common/rc index f17b19f2..1b7b2575 100644 --- a/common/rc +++ b/common/rc @@ -2311,7 +2311,7 @@ _require_scratch_swapfile() _require_scratch _require_command "$MKSWAP_PROG" "mkswap" - _scratch_mkfs >/dev/null + _scratch_mkfs >/dev/null 2>&1 # With mounting SELinux context(e.g. system_u:object_r:root_t:s0), # standard mkswap tried to reset the type of default context to -- 2.30.2