]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
util: Avoid null pointer dereference when setting QoS on OVS
authorJiri Denemark <jdenemar@redhat.com>
Fri, 29 Oct 2021 09:13:33 +0000 (11:13 +0200)
committerJiri Denemark <jdenemar@redhat.com>
Fri, 5 Nov 2021 08:25:55 +0000 (09:25 +0100)
Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
src/util/virnetdevopenvswitch.c

index 250726a633c685a307c2511fa6bf582f78bc1cdf..5dab545037605599c6f9d13585b09daf6d38d1d5 100644 (file)
@@ -759,7 +759,7 @@ virNetDevOpenvswitchInterfaceSetQos(const char *ifname,
         }
         virCommandAddArgList(cmd, vmid_ex_id, ifname_ex_id, NULL);
         if (virCommandRun(cmd, NULL) < 0) {
-            if (*queue_uuid) {
+            if (queue_uuid && *queue_uuid) {
                 virReportError(VIR_ERR_INTERNAL_ERROR,
                                _("Unable to set queue configuration on port %s"), ifname);
             } else {