[PATCH] Do not rely on a sane wc

Some implementations of wc pad the line number with white space, which
expr does not grok as a number.

Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Signed-off-by: Junio C Hamano <junkio@cox.net>
diff --git a/git-format-patch-script b/git-format-patch-script
index 994019e..51e8af0 100755
--- a/git-format-patch-script
+++ b/git-format-patch-script
@@ -109,7 +109,7 @@
 stripCommitHead='/^'"$_x40"' (from '"$_x40"')$/d'
 
 git-rev-list --merge-order "$junio" "^$linus" >$series
-total=`wc -l <$series`
+total=`wc -l <$series | tr -dc "[0-9]"`
 i=$total
 while read commit
 do