diff options
author | Eric Wong <normalperson@yhbt.net> | 2013-02-04 12:39:09 +0000 |
---|---|---|
committer | Eric Wong <normalperson@yhbt.net> | 2013-02-04 13:38:13 +0000 |
commit | e6faf9e26bcb172026a4984ecadbaa8b6789bcb7 (patch) | |
tree | 37d8b44818b1f62b7c285124073c85fa50e202e5 /t/t0044-autopush.sh | |
parent | f4e3bac180ff01256832f98655636f79b52f9d5b (diff) | |
download | rainbows-e6faf9e26bcb172026a4984ecadbaa8b6789bcb7.tar.gz |
On FreeBSD 9.0, "wc -l" emits leading whitespace, so filter it through tr -d '[:space:]' to eliminate it.
Diffstat (limited to 't/t0044-autopush.sh')
-rw-r--r-- | t/t0044-autopush.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/t/t0044-autopush.sh b/t/t0044-autopush.sh index 9faa61a..103f9fc 100644 --- a/t/t0044-autopush.sh +++ b/t/t0044-autopush.sh @@ -37,7 +37,7 @@ start_strace () { check_TCP_CORK () { nr=0 - while test 2 -gt $(grep TCP_CORK $strace_out | wc -l) + while test 2 -gt $(grep TCP_CORK $strace_out | count_lines) do nr=$(( $nr + 1 )) if test $nr -gt 30 @@ -48,7 +48,7 @@ check_TCP_CORK () { sleep 1 done - test 2 -eq $(grep TCP_CORK $strace_out | wc -l) + test 2 -eq $(grep TCP_CORK $strace_out | count_lines) fgrep 'SOL_TCP, TCP_CORK, [0],' $strace_out fgrep 'SOL_TCP, TCP_CORK, [1],' $strace_out } |