From 854616489105b0ce05e14f148ef088f8a6e854c6 Mon Sep 17 00:00:00 2001 From: "Andreas J. Koenig" Date: Sat, 27 Sep 2008 07:51:04 +0200 Subject: [PATCH] again wrong algorithm --- lib/File/Rsync/Mirror/Recentfile.pm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/File/Rsync/Mirror/Recentfile.pm b/lib/File/Rsync/Mirror/Recentfile.pm index 84bf102..f78f4d4 100644 --- a/lib/File/Rsync/Mirror/Recentfile.pm +++ b/lib/File/Rsync/Mirror/Recentfile.pm @@ -763,7 +763,8 @@ sub merge { } # calculate the target time span - my $epoch = $other_recent->[0] ? $other_recent->[0]{epoch} : $my_recent->[0] ? $my_recent->[0]{epoch} : undef; + my $myepoch = $my_recent->[0] ? $my_recent->[0]{epoch} : undef; + my $epoch = $other_recent->[0] ? $other_recent->[0]{epoch} : $myepoch; my $oldest_allowed = 0; my $something_done; if ($my_recent->[0]) { @@ -797,7 +798,7 @@ sub merge { and $oev->{type} eq "delete") { # do nothing } else { - if ($oevepoch > $epoch) { + if (!$myepoch || $oevepoch > $myepoch) { $something_done=1; } push @$recent, { epoch => $oev->{epoch}, path => $path, type => $oev->{type} }; -- 2.11.4.GIT