]> arthur.barton.de Git - bup.git/commitdiff
import-rsnapshot: exit with 1, not -1
authorGabriel Filion <gabster@lelutin.ca>
Sun, 21 Jun 2015 03:51:15 +0000 (23:51 -0400)
committerRob Browning <rlb@defaultvalue.org>
Sat, 4 Jul 2015 14:04:34 +0000 (09:04 -0500)
Using a negative exit code is a bashism and since we use /bin/sh to
interpret the script, we should avoid it.

This was reported by Raphael Geissert in a Debian bug report:

https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=772222

Signed-off-by: Gabriel Filion <gabster@lelutin.ca>
[rlb@defaultvalue.org: adjust commit message]
Reviewed-by: Rob Browning <rlb@defaultvalue.org>
Tested-by: Rob Browning <rlb@defaultvalue.org>
cmd/import-rsnapshot-cmd.sh

index d04fbbbcf02ccb67d1aecf63f411f8e76bc8b854..6ab398419a32b66d53a5e09c6e10b0b778cbf519 100755 (executable)
@@ -5,7 +5,7 @@ usage() {
     echo "Usage: bup import-rsnapshot [-n]" \
         "<path to snapshot_root> [<backuptarget>]"
     echo "-n,--dry-run: just print what would be done"
-    exit -1
+    exit 1
 }
 
 DRY_RUN=