From 3b709c9cfd1252c360978fdf44f1d825279682db Mon Sep 17 00:00:00 2001 From: Silvio Rhatto Date: Thu, 10 May 2012 16:48:51 -0300 Subject: [PATCH 1/3] Merge branches 'master' and 'bug/3721' into bug/3721 From bf5ada0f0357dd3b7500d03dd4a4a2f84282e8c1 Mon Sep 17 00:00:00 2001 From: Silvio Rhatto Date: Thu, 10 May 2012 16:53:52 -0300 Subject: [PATCH 2/3] Changing remaining 'exit' to 'fatal' at rsync handler (#3721) --- handlers/rsync.in | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/handlers/rsync.in b/handlers/rsync.in index 884a885..cb72886 100644 --- a/handlers/rsync.in +++ b/handlers/rsync.in @@ -391,8 +391,7 @@ function rotate_long { local metadata if [ ! -d "$backuproot" ]; then - echo "Debug: skipping rotate of $backuproot as it doesn't exist." - exit + fatal "Skipping rotate of $backuproot as it doesn't exist." fi for rottype in daily weekly monthly; do @@ -509,7 +508,7 @@ function rotate_long_remote { now=\`date +%s\` if [ ! -d "$backuproot" ]; then - echo "Debug: skipping rotate of $backuproot as it doesn't exist." + echo "Fatal: skipping rotate of $backuproot as it doesn't exist." exit fi From ba3e37595d7a8fbf9a881ab0b9b14146eb91f3a2 Mon Sep 17 00:00:00 2001 From: Silvio Rhatto Date: Thu, 10 May 2012 17:00:58 -0300 Subject: [PATCH 3/3] Changing a 'fatal' to a 'warning' on rsync handler. Using 'warning' and 'return' instead of a fatal at rotate_long if backuproot doesn't exist. Using a warning ensures that the backup action can process the other includes and not just exit. --- handlers/rsync.in | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/handlers/rsync.in b/handlers/rsync.in index cb72886..6fcda05 100644 --- a/handlers/rsync.in +++ b/handlers/rsync.in @@ -391,7 +391,8 @@ function rotate_long { local metadata if [ ! -d "$backuproot" ]; then - fatal "Skipping rotate of $backuproot as it doesn't exist." + warning "Skipping rotate of $backuproot as it doesn't exist." + return fi for rottype in daily weekly monthly; do