diff --git a/ChangeLog b/ChangeLog index 9db0346793..d3445b65be 100644 --- a/ChangeLog +++ b/ChangeLog @@ -10,6 +10,12 @@ (lone zb subtotals, spurious 'recursive-bal, typos) needed to make the new account-summary.scm work. + Thomas Bushnell's patch to protect non-backup pruning (#164875) + * src/backend/file/gnc-backend-file.c: + When working on the file foo.xac, backups are named + foo.DATE.xac. But the backup file pruner will prune any old + file named foo.DATE.anything. + 2005-01-29 Christian Stimming * configure.in, src/tax/us/gncmod-tax-us.c, diff --git a/src/backend/file/gnc-backend-file.c b/src/backend/file/gnc-backend-file.c index 3356cbf153..b1fecc539d 100644 --- a/src/backend/file/gnc-backend-file.c +++ b/src/backend/file/gnc-backend-file.c @@ -665,6 +665,7 @@ gnc_file_be_remove_old_files(FileBackend *be) /* Make sure this file actually has a date before unlinking */ if (res && res != name+pathlen+1 && /* We consumed some but not all of the filename */ + !strcmp(res, ".xac") && file_time > 0 && /* we actually have a reasonable time and it is old enough */ days > file_retention_days)