5
0
mirror of git://git.proxmox.com/git/pve-guest-common.git synced 2025-01-12 09:17:50 +03:00

replication: sort time stamps numerically

This commit is contained in:
Wolfgang Bumiller 2017-06-28 09:02:29 +02:00 committed by Dietmar Maurer
parent 1b82f17117
commit 621b955fb8

View File

@ -299,7 +299,7 @@ sub get_next_job {
my $jobb = $jobs->{$b};
my $sa = $joba->{state};
my $sb = $jobb->{state};
my $res = $sa->{last_iteration} cmp $sb->{last_iteration};
my $res = $sa->{last_iteration} <=> $sb->{last_iteration};
return $res if $res != 0;
$res = $joba->{next_sync} <=> $jobb->{next_sync};
return $res if $res != 0;