]> xenbits.xensource.com Git - libvirt.git/commitdiff
virnetdevip: Avoid cast align warning
authorJán Tomko <jtomko@redhat.com>
Tue, 15 Jan 2019 12:00:52 +0000 (13:00 +0100)
committerJán Tomko <jtomko@redhat.com>
Tue, 15 Jan 2019 12:00:52 +0000 (13:00 +0100)
Commit 7282f455a got rid of the VIR_WARNINGS_NO_CAST_ALIGN macro
when refactoring the code and broke the build with clang.

Signed-off-by: Ján Tomko <jtomko@redhat.com>
src/util/virnetdevip.c

index b6df422cd1d8dc7365378450a4f9b4e087915213..f39467f1d65a5280f3ec08da53402fd0324b6c30 100644 (file)
@@ -599,7 +599,9 @@ virNetDevIPCheckIPv6ForwardingCallback(struct nlmsghdr *resp,
             data->hasRARoutes = true;
 
             len -= NLMSG_ALIGN(nh->rtnh_len);
+            VIR_WARNINGS_NO_CAST_ALIGN
             nh = RTNH_NEXT(nh);
+            VIR_WARNINGS_RESET
         }
     }