]> git.proxmox.com Git - qemu-server.git/commitdiff
fixup: remove unneeded if branch
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Wed, 21 Mar 2018 10:12:26 +0000 (11:12 +0100)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Wed, 21 Mar 2018 10:15:35 +0000 (11:15 +0100)
$readfrom equals $archive here, and we're already in the branch with
the condition that both are not equal to '-'

PVE/QemuServer.pm

index f1ed6b6bc97ef6404a5f19645775a60700116b83..deb58eddd46a82d605d0c1cb9b5edecc87cdac5f 100644 (file)
@@ -5662,10 +5662,7 @@ sub restore_vma_archive {
            my $readlimit = PVE::Storage::get_bandwidth_limit('restore', [$sid], $bwlimit);
            if ($readlimit) {
                print STDERR "applying read rate limit: $readlimit\n";
-               my $cstream = ['cstream', '-t', $readlimit*1024];
-               if ($readfrom ne '-') {
-                   push @$cstream, '--', $readfrom;
-               }
+               my $cstream = ['cstream', '-t', $readlimit*1024, '--', $readfrom];
                $add_pipe->($cstream);
            }
        }