fix case where destination does not yet exist - no backup can be made

This commit is contained in:
Seth Vidal 2012-08-09 15:33:05 -04:00
parent 28e9b1128f
commit 588b129018

View file

@ -75,6 +75,7 @@ def main():
if md5sum_src != md5sum_dest: if md5sum_src != md5sum_dest:
try: try:
if backup: if backup:
if os.path.exists(dest):
success, msg = backuplocal(dest) success, msg = backuplocal(dest)
if not success: if not success:
module.fail_jason(msg=msg) module.fail_jason(msg=msg)