]> xenbits.xensource.com Git - libvirt.git/commit
build: fix build on cygwin
authorEric Blake <eblake@redhat.com>
Sun, 3 Aug 2014 02:47:36 +0000 (20:47 -0600)
committerEric Blake <eblake@redhat.com>
Sun, 3 Aug 2014 02:52:34 +0000 (20:52 -0600)
commit478d93ad1f83084bb0277fec07e1ef441a09018f
tree3343fd383e07e3e8f0a3ff7fc3855b33c093e044
parentc0788af07d08f0e2297736764766d78ff72ae034
build: fix build on cygwin

Cygwin has getifaddrs(), but not AF_LINK, leading to:

util/virstats.c: In function 'virNetInterfaceStats':
util/virstats.c:138:41: error: 'AF_LINK' undeclared (first use in this function)
         if (ifa->ifa_addr->sa_family != AF_LINK)
...

* src/util/virstats.c (virNetInterfaceStats): Only use getifaddrs
if AF_LINK is present.

Signed-off-by: Eric Blake <eblake@redhat.com>
src/util/virstats.c