From 47ff88db9da3cd140818db8dd824f5b027020d6c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rolf=20Sch=C3=A4uble?= Date: Tue, 20 Jun 2017 11:42:35 +0200 Subject: [PATCH] Fix #91: do not use exit codes > 255 Exit codes > 256 are treated by bash as `exit_code % 256`, which is confusing. Furthermore, using code 256 is particularly problematic, as 256%256=0, which means success, and is not was was intended here. For further information about special exit codes, see http://tldp.org/LDP/abs/html/exitcodes.html. --- syncoid | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/syncoid b/syncoid index 9345fea..8ccdd23 100755 --- a/syncoid +++ b/syncoid @@ -764,7 +764,7 @@ sub getmatchingsnapshot { print " replication must be to a NON EXISTENT DATASET, which will\n"; print " then be CREATED BY the initial replication process.\n\n"; } - exit 256; + exit 3; } sub newsyncsnap {