[LTP] [PATCH ltp 3/6] numa/numa01.sh: Fix shellcheck issue SC2069

Yixin Zhang yixin.zhang@intel.com
Fri Apr 20 05:18:52 CEST 2018


error: The order of the 2>&1 and the redirect matters. The 2>&1 has to
be last. [SC2069]

Signed-off-by: Yixin Zhang <yixin.zhang@intel.com>
---
 testcases/kernel/numa/numa01.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/testcases/kernel/numa/numa01.sh b/testcases/kernel/numa/numa01.sh
index fd3b4be64..27a2f2f7c 100755
--- a/testcases/kernel/numa/numa01.sh
+++ b/testcases/kernel/numa/numa01.sh
@@ -315,7 +315,7 @@ test8()
 	# Memory will be allocated using round robin on nodes.
 	Exp_incr=$(echo "$MB / $total_nodes" |bc)
 
-	numactl --interleave=all memhog -r1000000 1MB 2>&1 >ltp_numa_test8.log &
+	numactl --interleave=all memhog -r1000000 1MB >ltp_numa_test8.log 2>&1 &
 	pid=$!
 
 	local retries=20
-- 
2.14.1



More information about the ltp mailing list