[PATCH] t0060: fix whitespace in "wc -c" invocation

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

 



Some platforms like to stick extra whitespace in the output
of "wc -c"; using the result without quotes gets the shell
to collapse the whitespace.

Signed-off-by: Jeff King <peff@xxxxxxxx>
---
On top of 'next'.

I noticed the breakage on Solaris; I suspect AIX is broken, too.

 t/t0060-path-utils.sh |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/t/t0060-path-utils.sh b/t/t0060-path-utils.sh
index 86000e2..53cf1f8 100755
--- a/t/t0060-path-utils.sh
+++ b/t/t0060-path-utils.sh
@@ -17,7 +17,7 @@ norm_path() {
 # which means that the path / accounts for this many characters:
 rootoff=$(test-path-utils normalize_path_copy / | wc -c)
 # Account for the trailing LF:
-if test "$rootoff" = 2; then
+if test $rootoff = 2; then
 	rootoff=	# we are on Unix
 else
 	rootoff=$(($rootoff-1))
-- 
1.6.2.1.276.gd47fa
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux