diff options
author | Colin Smith <colin@pfsense.org> | 2005-05-18 03:20:47 +0000 |
---|---|---|
committer | Colin Smith <colin@pfsense.org> | 2005-05-18 03:20:47 +0000 |
commit | 8a4219676ff7a300255cee892c53f2df23a27b8d (patch) | |
tree | 1c107245a73f40ada86a283411ee0cee5e3c7b48 /etc/inc | |
parent | 7e0e716ac99f1e36bb2ef69e74f272c710c3bb75 (diff) | |
download | pfsense-8a4219676ff7a300255cee892c53f2df23a27b8d.zip pfsense-8a4219676ff7a300255cee892c53f2df23a27b8d.tar.gz |
Fix glob pattern.
Diffstat (limited to 'etc/inc')
-rw-r--r-- | etc/inc/config.inc | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/etc/inc/config.inc b/etc/inc/config.inc index ce1e229..ce18221 100644 --- a/etc/inc/config.inc +++ b/etc/inc/config.inc @@ -969,12 +969,11 @@ function cleanup_backupcache($revisions = "all") { if(file_exists($g['cf_conf_path'] . '/backup/backup.cache')) { $backups = get_backups(); $newbaks = array(); - $bakfiles = glob($g['cf_conf_path'] . "/backup/*"); + $bakfiles = glob($g['cf_conf_path'] . "/backup/config-*"); $baktimes = $backups['versions']; $tocache = array(); unset($backups['versions']); foreach($bakfiles as $backup) { // Check for backups in the directory not represented in the cache. - if(stristr($backup, 'backup.cache')) continue; $tocheck = array_shift(explode('.', array_pop(explode('-', $backup)))); if(!in_array($tocheck, $baktimes)) { $i = true; |