Commit c2226070 authored by Wayne Davison's avatar Wayne Davison

Don't add the "protect" filter rule for backup-suffix filenames

if --backup was not specified.
parent d5782b52
...@@ -1262,7 +1262,7 @@ int parse_arguments(int *argc, const char ***argv, int frommain) ...@@ -1262,7 +1262,7 @@ int parse_arguments(int *argc, const char ***argv, int frommain)
snprintf(err_buf, sizeof err_buf, snprintf(err_buf, sizeof err_buf,
"--suffix cannot be a null string without --backup-dir\n"); "--suffix cannot be a null string without --backup-dir\n");
return 0; return 0;
} else if (delete_mode && !delete_excluded) { } else if (make_backups && delete_mode && !delete_excluded) {
snprintf(backup_dir_buf, sizeof backup_dir_buf, snprintf(backup_dir_buf, sizeof backup_dir_buf,
"P *%s", backup_suffix); "P *%s", backup_suffix);
parse_rule(&filter_list, backup_dir_buf, 0, 0); parse_rule(&filter_list, backup_dir_buf, 0, 0);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment