Ensure GET_VLAN_VID_CMD is always defined

The RHEL4 vintage header files do not define GET_VLAN_VID_CMD.
Conditionally define it in our source, since the kernel can
raise a runtime error if it isn't supported

Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
This commit is contained in:
Daniel P. Berrange committed 2013-03-07 18:08:31 +00:00
1 parent 564e7d38a2
commit 3ed2e54500
1 file changed
+1 -1
+1 -1
View File
@@ -672,7 +672,7 @@ int virNetDevGetIndex(const char *ifname ATTRIBUTE_UNUSED,
#endif /* ! SIOCGIFINDEX */
#if defined(SIOCGIFVLAN) && defined(HAVE_STRUCT_IFREQ)
#if defined(SIOCGIFVLAN) && defined(HAVE_STRUCT_IFREQ) && defined(GET_VLAN_VID_CMD)
int virNetDevGetVLanID(const char *ifname, int *vlanid)
{
struct vlan_ioctl_args vlanargs = {