[libvirt] Don't use private struct member names of in6_addr

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



__in6_u.__u6_addr16 is the private name for this struct member,
s6_addr16 is the public one. Our buildserver revealed this problem,
because for some reason the internal names are missing the __ prefix
there.

Matthias
diff --git a/src/util/network.c b/src/util/network.c
index abd866c..5e3cb3a 100644
--- a/src/util/network.c
+++ b/src/util/network.c
@@ -46,7 +46,7 @@ static int getIPv6Addr(virSocketAddrPtr addr, virIPv6AddrPtr tab) {
     if ((addr == NULL) || (tab == NULL) || (addr->stor.ss_family != AF_INET6))
         return(-1);
 
-    val = (virIPv6AddrPtr) &(addr->inet6.sin6_addr.__in6_u.__u6_addr16);
+    val = (virIPv6AddrPtr) &(addr->inet6.sin6_addr.s6_addr16);
 
     for (i = 0;i < 8;i++) {
         (*tab)[i] = ntohs((*val)[i]);
--
Libvir-list mailing list
Libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]