all lists on lists.proxmox.com
 help / color / mirror / Atom feed
* [pve-devel] [PATCH qemu-server] api: clone: sort vm disks to keep numbers consistent
@ 2021-05-26 14:19 Lorenz Stechauner
  2021-05-26 15:36 ` [pve-devel] applied: " Thomas Lamprecht
  0 siblings, 1 reply; 2+ messages in thread
From: Lorenz Stechauner @ 2021-05-26 14:19 UTC (permalink / raw)
  To: pve-devel

reported by user in forum:
https://forum.proxmox.com/threads/problem-when-copying-template-with-2-discs.89851/

Signed-off-by: Lorenz Stechauner <l.stechauner@proxmox.com>
---
 PVE/API2/Qemu.pm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/PVE/API2/Qemu.pm b/PVE/API2/Qemu.pm
index c56b609..24dba86 100644
--- a/PVE/API2/Qemu.pm
+++ b/PVE/API2/Qemu.pm
@@ -3157,7 +3157,7 @@ __PACKAGE__->register_method({
 		    my $total_jobs = scalar(keys %{$drives});
 		    my $i = 1;
 
-		    foreach my $opt (keys %$drives) {
+		    foreach my $opt (sort keys %$drives) {
 			my $drive = $drives->{$opt};
 			my $skipcomplete = ($total_jobs != $i); # finish after last drive
 			my $completion = $skipcomplete ? 'skip' : 'complete';
-- 
2.20.1





^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-05-26 15:36 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-26 14:19 [pve-devel] [PATCH qemu-server] api: clone: sort vm disks to keep numbers consistent Lorenz Stechauner
2021-05-26 15:36 ` [pve-devel] applied: " Thomas Lamprecht

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal