summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDirk Engling <erdgeist@erdgeist.org>2014-02-10 15:36:33 +0100
committerDirk Engling <erdgeist@erdgeist.org>2014-02-10 15:36:33 +0100
commita3e3fddaf78999916228172fbf5b718b59719b7f (patch)
tree81b4f151dc8e3d1c9cbe98a676be2f3ca54aa681 /src
parentae1f17a7b0abbc425f33106c666f1bc71e1b4711 (diff)
Avoid div by zero when operator precedence screws up
Diffstat (limited to 'src')
-rwxr-xr-xsrc/makecolumns.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/makecolumns.sh b/src/makecolumns.sh
index 476ce90..7f61ea7 100755
--- a/src/makecolumns.sh
+++ b/src/makecolumns.sh
@@ -49,7 +49,7 @@ do_decompress_old() {
49 for archive in *.lha; do 49 for archive in *.lha; do
50 lha x ${archive} > /dev/null 50 lha x ${archive} > /dev/null
51 rm ${archive} 51 rm ${archive}
52 [ 1 -eq $(( ( (processed+=1) * 20 ) / numfiles > reported )) ] && printf "%d%% " $(( (reported+=1) * 5 )) 52 [ 1 -eq $(( ( ( (processed+=1) * 20 ) / numfiles ) > reported )) ] && printf "%d%% " $(( (reported+=1) * 5 ))
53 done 53 done
54 [ $reported -lt 10 ] && printf "100% " 54 [ $reported -lt 10 ] && printf "100% "
55 printf "done.\n" 55 printf "done.\n"