5
0
mirror of git://git.proxmox.com/git/pve-zsync.git synced 2025-01-03 09:17:37 +03:00

Revert "fix: check for incremental sync snapshot."

This reverts commit 723623e885.
This commit is contained in:
Thomas Lamprecht 2020-03-19 13:02:02 +01:00
parent 723623e885
commit fd8052006b

View File

@ -933,7 +933,6 @@ sub snapshot_destroy {
}
}
# check if snapshot for incremental sync exist on dest side
sub snapshot_exist {
my ($source , $dest, $method, $dest_user) = @_;
@ -943,16 +942,22 @@ sub snapshot_exist {
my $path = $dest->{all};
$path .= "/$source->{last_part}" if $source->{last_part};
$path .= "\@$source->{last_snap}";
$path .= "\@$source->{old_snap}";
push @$cmd, $path;
eval {run_cmd($cmd)};
my $text = "";
eval {$text =run_cmd($cmd);};
if (my $erro =$@) {
warn "WARN: $erro";
return undef;
}
return 1;
while ($text && $text =~ s/^(.*?)(\n|$)//) {
my $line =$1;
return 1 if $line =~ m/^.*$source->{old_snap}$/;
}
}
sub send_image {