[PATCH] Exit with status 0 on --check-destination-dir if no check is needed

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

[PATCH] Exit with status 0 on --check-destination-dir if no check is needed

Charles Duffy-6
See attached patch. I believe this makes more sense than exiting with
status 1 (indicating an error), as simply having nothing to do is a
harmless, valid state.

--- rdiff-backup-1.0.4/rdiff_backup/Main.py.orig        2006-01-31 13:36:55.505083666 -0600
+++ rdiff-backup-1.0.4/rdiff_backup/Main.py     2006-01-31 13:36:57.740048887 -0600
@@ -857,7 +857,7 @@
                Log.FatalError("No destination dir found at %s" % (dest_rp.path,))
        elif need_check == 0:
                Log.FatalError("Destination dir %s does not need checking" %
-                                          (dest_rp.path,))
+                                          (dest_rp.path,), errlevel = 0)
        init_user_group_mapping(dest_rp.conn)
        dest_rp.conn.regress.Regress(dest_rp)



_______________________________________________
rdiff-backup-users mailing list at [hidden email]
http://lists.nongnu.org/mailman/listinfo/rdiff-backup-users
Wiki URL: http://rdiff-backup.solutionsfirst.com.au/index.php/RdiffBackupWiki
Reply | Threaded
Open this post in threaded view
|

Re: [PATCH] Exit with status 0 on --check-destination-dir if no check is needed

Ben Escoto
>>>>> Charles Duffy <[hidden email]>
>>>>> wrote the following on Tue, 31 Jan 2006 13:44:30 -0600
> See attached patch. I believe this makes more sense than exiting with
> status 1 (indicating an error), as simply having nothing to do is a
> harmless, valid state.

Checked in to stable and devel branches.  I plan to look at your other
messages later (I'm getting a bit backlogged at the moment).


--
Ben Escoto

_______________________________________________
rdiff-backup-users mailing list at [hidden email]
http://lists.nongnu.org/mailman/listinfo/rdiff-backup-users
Wiki URL: http://rdiff-backup.solutionsfirst.com.au/index.php/RdiffBackupWiki

attachment0 (196 bytes) Download Attachment