Merge pull request #119 from JakobR/fix

Fix off-by-one error causing too many snapshots under certain conditions
This commit is contained in:
Jim Salter 2017-08-04 13:44:45 -04:00 committed by GitHub
commit f16eff97fc
1 changed files with 1 additions and 1 deletions

2
sanoid
View File

@ -318,7 +318,7 @@ sub take_snapshots {
# reconstruct our human-formatted most recent preferred snapshot time into an epoch time, to compare with the epoch of our most recent snapshot
my $maxage = time()-$lastpreferred;
if ( $newestage >= $maxage ) {
if ( $newestage > $maxage ) {
# update to most current possible datestamp
%datestamp = get_date();
# print "we should have had a $type snapshot of $path $maxage seconds ago; most recent is $newestage seconds old.\n";