[PATCH 1/6] tests: fix fincore, don't use variable COLUMNS

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Ruediger Meier <ruediger.meier@xxxxxxxxxxx>

COLUMNS is automatically set by bash and may result in stupid
errors like

  fincore: unknown column: 160

Signed-off-by: Ruediger Meier <ruediger.meier@xxxxxxxxxxx>
---
 tests/ts/fincore/count | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/tests/ts/fincore/count b/tests/ts/fincore/count
index 7a1c5d426..0151016ee 100755
--- a/tests/ts/fincore/count
+++ b/tests/ts/fincore/count
@@ -70,7 +70,7 @@ function run_dd_test
 		_dd if=/dev/zero of=$input count=1 bs=$bs $flags || return
     fi
 
-    $TS_CMD_FINCORE --output $COLUMNS  --bytes --noheadings $input
+    $TS_CMD_FINCORE --output $OUT_COLUMNS  --bytes --noheadings $input
 
     footer "$?"
 }
@@ -90,7 +90,7 @@ function run_dd_dd_test
     _dd if=/dev/zero of=$input count=1 bs=$bs $flags0 || return
     _dd if=/dev/zero of=$input count=1 bs=$bs $flags1 || return
 
-    $TS_CMD_FINCORE --output $COLUMNS --bytes --noheadings $input
+    $TS_CMD_FINCORE --output $OUT_COLUMNS --bytes --noheadings $input
 
     footer "$?"
 }
@@ -102,10 +102,10 @@ WINDOW_SIZE=$(( 32 * 1024 * PAGE_SIZE ))
 # we use PAGE_SIZE dependent output for a few systems
 if test -f "$TS_EXPECTED.$PAGE_SIZE"; then
 	TS_EXPECTED+=".$PAGE_SIZE"
-	COLUMNS="PAGES,SIZE,FILE"
+	OUT_COLUMNS="PAGES,SIZE,FILE"
 else
 	TS_EXPECTED+=".nosize"
-	COLUMNS="PAGES,FILE"
+	OUT_COLUMNS="PAGES,FILE"
 fi
 
 
@@ -122,7 +122,7 @@ input=
     INPUT="${INPUT} ${input}"
 
     header "NO EXCITING FILE"
-    $TS_CMD_FINCORE --output $COLUMNS --bytes --noheadings $input
+    $TS_CMD_FINCORE --output $OUT_COLUMNS --bytes --noheadings $input
     footer "$?"
 } >> $TS_OUTPUT 2>&1
 
@@ -220,7 +220,7 @@ input=
 
 {
     header "MULTIPLE FILES"
-    $TS_CMD_FINCORE --output $COLUMNS --bytes $INPUT
+    $TS_CMD_FINCORE --output $OUT_COLUMNS --bytes $INPUT
     footer "$?"
 } >> $TS_OUTPUT 2>&1
 
-- 
2.12.3

--
To unsubscribe from this list: send the line "unsubscribe util-linux" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux