From: Andre Noll <maan@oka.kyb.local>
Date: Thu, 26 Jul 2007 13:40:42 +0000 (+0200)
Subject: gsu: Fix two bashisms.
X-Git-Url: https://git.tue.mpg.de/?a=commitdiff_plain;h=cfcfff151c607e910616ff04ac1a39650ee29277;p=gsu.git

gsu: Fix two bashisms.

Always include the '$', even in math expressions where bash doesn't
need it.
---

diff --git a/funcs/gsu b/funcs/gsu
index 221aad6..106663a 100644
--- a/funcs/gsu
+++ b/funcs/gsu
@@ -17,7 +17,7 @@ $gsu_errors
 		#echo "a:$a,  b: $b"
 		gsu_error_txt[i]="$b"
 		eval $a=$i
-		i=$((i + 1))
+		i=$(($i + 1))
 	done << EOF
 	$gsu_errors
 EOF
@@ -161,8 +161,8 @@ gsu_print_available_commands()
 	gsu_short_msg "Available commands:"
 	for i in $gsu_cmds; do
 		printf "$i"
-		count=$((count + 1))
-		if test $((count % 4)) -eq 0; then
+		count=$(($count + 1))
+		if test $(($count % 4)) -eq 0; then
 			echo
 		else
 			printf "\t"