]> git.proxmox.com Git - qemu-server.git/commitdiff
qxl max_outputs: ostype can be undefined, assume linux
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Wed, 20 Nov 2019 14:10:16 +0000 (15:10 +0100)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Wed, 20 Nov 2019 14:29:12 +0000 (15:29 +0100)
Out code behaves like either l26 or other when the ostype is
undefined, both are not common as our webinterface _always_ sets the
ostype.

If one configured QXL with a VM as output device but does not has an
ostype set, and that works without "max_outputs=4" it really should
work with none too.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
PVE/QemuServer.pm

index eb1c77d95366ff972085716d98630098143b05e1..561a54fb5f7994b3462933f0351a71700eb98f90 100644 (file)
@@ -2189,7 +2189,7 @@ sub print_vga_device {
     if ($qxlnum) {
        $type = $id ? 'qxl' : 'qxl-vga';
 
-       if ($conf->{ostype} =~ m/^l(?=\d)/) {
+       if (!$conf->{ostype} || $conf->{ostype} =~ m/^(?:l\d\d)|(?:other)$/) {
            # set max outputs so linux can have up to 4 qxl displays with one device
            $max_outputs = ",max_outputs=4";
        }