Variables/fields named 'interface' clash with system
header symbols on some platforms.
Signed-off-by: Daniel P. Berrange <berrange(a)redhat.com>
---
daemon/remote.c | 4 ++--
include/libvirt/libvirt.h.in | 2 +-
src/libvirt.c | 2 +-
src/network/bridge_driver.c | 2 +-
src/remote/remote_driver.c | 2 +-
src/remote/remote_protocol.x | 2 +-
src/remote_protocol-structs | 2 +-
7 files changed, 8 insertions(+), 8 deletions(-)
Pushed as build-breaker fix
diff --git a/daemon/remote.c b/daemon/remote.c
index f4ec8ea..ae19b2a 100644
--- a/daemon/remote.c
+++ b/daemon/remote.c
@@ -6223,7 +6223,7 @@ remoteSerializeDHCPLease(remote_network_dhcp_lease *lease_dst,
virNetworkDHCPLea
lease_dst->type = lease_src->type;
lease_dst->prefix = lease_src->prefix;
- if (VIR_STRDUP(lease_dst->interface, lease_src->interface) < 0 ||
+ if (VIR_STRDUP(lease_dst->iface, lease_src->iface) < 0 ||
VIR_STRDUP(lease_dst->ipaddr, lease_src->ipaddr) < 0 ||
VIR_STRDUP(*mac_tmp, lease_src->mac) < 0 ||
VIR_STRDUP(*iaid_tmp, lease_src->iaid) < 0 ||
@@ -6248,7 +6248,7 @@ remoteSerializeDHCPLease(remote_network_dhcp_lease *lease_dst,
virNetworkDHCPLea
VIR_FREE(hostname_tmp);
VIR_FREE(clientid_tmp);
VIR_FREE(lease_dst->ipaddr);
- VIR_FREE(lease_dst->interface);
+ VIR_FREE(lease_dst->iface);
return -1;
}
diff --git a/include/libvirt/libvirt.h.in b/include/libvirt/libvirt.h.in
index b3120e2..7e695a3 100644
--- a/include/libvirt/libvirt.h.in
+++ b/include/libvirt/libvirt.h.in
@@ -5174,7 +5174,7 @@ typedef enum {
typedef struct _virNetworkDHCPLease virNetworkDHCPLease;
typedef virNetworkDHCPLease *virNetworkDHCPLeasePtr;
struct _virNetworkDHCPLease {
- char *interface; /* Network interface name */
+ char *iface; /* Network interface name */
long long expirytime; /* Seconds since epoch */
int type; /* virIPAddrType */
char *mac; /* MAC address */
diff --git a/src/libvirt.c b/src/libvirt.c
index f4d03bc..a0cdfa2 100644
--- a/src/libvirt.c
+++ b/src/libvirt.c
@@ -21176,7 +21176,7 @@ virNetworkDHCPLeaseFree(virNetworkDHCPLeasePtr lease)
{
if (!lease)
return;
- VIR_FREE(lease->interface);
+ VIR_FREE(lease->iface);
VIR_FREE(lease->mac);
VIR_FREE(lease->iaid);
VIR_FREE(lease->ipaddr);
diff --git a/src/network/bridge_driver.c b/src/network/bridge_driver.c
index d5577e0..a407c6e 100644
--- a/src/network/bridge_driver.c
+++ b/src/network/bridge_driver.c
@@ -3490,7 +3490,7 @@ networkGetDHCPLeasesHelper(virNetworkObjPtr obj,
if ((VIR_STRDUP(lease->mac, mac_tmp) < 0) ||
(VIR_STRDUP(lease->ipaddr, ip_tmp) < 0) ||
- (VIR_STRDUP(lease->interface, obj->def->bridge) < 0))
+ (VIR_STRDUP(lease->iface, obj->def->bridge) < 0))
goto error;
/* Fields that can be NULL */
diff --git a/src/remote/remote_driver.c b/src/remote/remote_driver.c
index af79cb5..76ce4a9 100644
--- a/src/remote/remote_driver.c
+++ b/src/remote/remote_driver.c
@@ -7557,7 +7557,7 @@ remoteSerializeDHCPLease(virNetworkDHCPLeasePtr lease_dst,
remote_network_dhcp_l
lease_dst->type = lease_src->type;
lease_dst->prefix = lease_src->prefix;
- if (VIR_STRDUP(lease_dst->interface, lease_src->interface) < 0)
+ if (VIR_STRDUP(lease_dst->iface, lease_src->iface) < 0)
goto error;
if (VIR_STRDUP(lease_dst->ipaddr, lease_src->ipaddr) < 0)
diff --git a/src/remote/remote_protocol.x b/src/remote/remote_protocol.x
index b5f44f7..4b75bdb 100644
--- a/src/remote/remote_protocol.x
+++ b/src/remote/remote_protocol.x
@@ -3022,7 +3022,7 @@ struct remote_node_get_free_pages_ret {
};
struct remote_network_dhcp_lease {
- remote_nonnull_string interface;
+ remote_nonnull_string iface;
hyper expirytime;
int type;
remote_string mac;
diff --git a/src/remote_protocol-structs b/src/remote_protocol-structs
index d363247..222f125 100644
--- a/src/remote_protocol-structs
+++ b/src/remote_protocol-structs
@@ -2486,7 +2486,7 @@ struct remote_node_get_free_pages_ret {
} counts;
};
struct remote_network_dhcp_lease {
- remote_nonnull_string interface;
+ remote_nonnull_string iface;
int64_t expirytime;
int type;
remote_string mac;
--
1.9.3
Show replies by date