Skip to content

Commit 838ed26

Browse files
committed
Update: Allow backup to complete if "file changed as we read it"
1 parent 2233652 commit 838ed26

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

server/lib/classes/cron.d/500-backup_mail.inc.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ public function onRunJob() {
152152
}
153153
}
154154

155-
if($retval <= 1){
155+
if($retval == 0 || ($backup_mode != 'userzip' && $retval == 1) || ($backup_mode == 'userzip' && $retval == 12)){// tar can return 1, zip can return 12(due to harmless warings) and still create valid backups
156156
chown($mail_backup_dir.'/'.$mail_backup_file, $backupusername);
157157
chgrp($mail_backup_dir.'/'.$mail_backup_file, $backupgroup);
158158
chmod($mail_backup_dir.'/'.$mail_backup_file, 0640);

0 commit comments

Comments
 (0)