Use G_GNUC_UNUSED from GLib instead of ATTRIBUTE_UNUSED.
Signed-off-by: Ján Tomko <jtomko(a)redhat.com>
---
src/nwfilter/nwfilter_dhcpsnoop.c | 20 ++++++++++----------
src/nwfilter/nwfilter_driver.c | 22 +++++++++++-----------
src/nwfilter/nwfilter_ebiptables_driver.c | 12 ++++++------
src/nwfilter/nwfilter_gentech_driver.c | 2 +-
src/nwfilter/nwfilter_learnipaddr.c | 12 ++++++------
5 files changed, 34 insertions(+), 34 deletions(-)
diff --git a/src/nwfilter/nwfilter_dhcpsnoop.c b/src/nwfilter/nwfilter_dhcpsnoop.c
index c82457989e..dae2ad611d 100644
--- a/src/nwfilter/nwfilter_dhcpsnoop.c
+++ b/src/nwfilter/nwfilter_dhcpsnoop.c
@@ -661,7 +661,7 @@ virNWFilterSnoopReqUnlock(virNWFilterSnoopReqPtr req)
* virNWFilterSnoopReqRelease - hash table free function to kill a request
*/
static void
-virNWFilterSnoopReqRelease(void *req0, const void *name ATTRIBUTE_UNUSED)
+virNWFilterSnoopReqRelease(void *req0, const void *name G_GNUC_UNUSED)
{
virNWFilterSnoopReqPtr req = req0;
@@ -1826,8 +1826,8 @@ virNWFilterSnoopLeaseFileSave(virNWFilterSnoopIPLeasePtr ipl)
*/
static int
virNWFilterSnoopPruneIter(const void *payload,
- const void *name ATTRIBUTE_UNUSED,
- const void *data ATTRIBUTE_UNUSED)
+ const void *name G_GNUC_UNUSED,
+ const void *data G_GNUC_UNUSED)
{
virNWFilterSnoopReqPtr req = (virNWFilterSnoopReqPtr)payload;
bool del_req;
@@ -1856,7 +1856,7 @@ virNWFilterSnoopPruneIter(const void *payload,
*/
static int
virNWFilterSnoopSaveIter(void *payload,
- const void *name ATTRIBUTE_UNUSED,
+ const void *name G_GNUC_UNUSED,
void *data)
{
virNWFilterSnoopReqPtr req = payload;
@@ -2023,8 +2023,8 @@ virNWFilterSnoopJoinThreads(void)
*/
static int
virNWFilterSnoopRemAllReqIter(const void *payload,
- const void *name ATTRIBUTE_UNUSED,
- const void *data ATTRIBUTE_UNUSED)
+ const void *name G_GNUC_UNUSED,
+ const void *data G_GNUC_UNUSED)
{
virNWFilterSnoopReqPtr req = (virNWFilterSnoopReqPtr)payload;
@@ -2200,7 +2200,7 @@ virNWFilterDHCPSnoopInit(void)
}
void
-virNWFilterDHCPSnoopEnd(const char *ifname ATTRIBUTE_UNUSED)
+virNWFilterDHCPSnoopEnd(const char *ifname G_GNUC_UNUSED)
{
return;
}
@@ -2212,9 +2212,9 @@ virNWFilterDHCPSnoopShutdown(void)
}
int
-virNWFilterDHCPSnoopReq(virNWFilterTechDriverPtr techdriver ATTRIBUTE_UNUSED,
- virNWFilterBindingDefPtr binding ATTRIBUTE_UNUSED,
- virNWFilterDriverStatePtr driver ATTRIBUTE_UNUSED)
+virNWFilterDHCPSnoopReq(virNWFilterTechDriverPtr techdriver G_GNUC_UNUSED,
+ virNWFilterBindingDefPtr binding G_GNUC_UNUSED,
+ virNWFilterDriverStatePtr driver G_GNUC_UNUSED)
{
virReportError(VIR_ERR_INTERNAL_ERROR,
_("libvirt was not compiled with libpcap and \""
diff --git a/src/nwfilter/nwfilter_driver.c b/src/nwfilter/nwfilter_driver.c
index aef5bd4c7f..fbdf250934 100644
--- a/src/nwfilter/nwfilter_driver.c
+++ b/src/nwfilter/nwfilter_driver.c
@@ -80,9 +80,9 @@ static void nwfilterDriverUnlock(void)
#ifdef WITH_FIREWALLD
static DBusHandlerResult
-nwfilterFirewalldDBusFilter(DBusConnection *connection ATTRIBUTE_UNUSED,
+nwfilterFirewalldDBusFilter(DBusConnection *connection G_GNUC_UNUSED,
DBusMessage *message,
- void *user_data ATTRIBUTE_UNUSED)
+ void *user_data G_GNUC_UNUSED)
{
if (dbus_message_is_signal(message, DBUS_INTERFACE_DBUS,
"NameOwnerChanged") ||
@@ -154,7 +154,7 @@ nwfilterDriverRemoveDBusMatches(void)
}
static int
-nwfilterDriverInstallDBusMatches(DBusConnection *sysbus ATTRIBUTE_UNUSED)
+nwfilterDriverInstallDBusMatches(DBusConnection *sysbus G_GNUC_UNUSED)
{
return 0;
}
@@ -177,8 +177,8 @@ virNWFilterTriggerRebuildImpl(void *opaque)
*/
static int
nwfilterStateInitialize(bool privileged,
- virStateInhibitCallback callback ATTRIBUTE_UNUSED,
- void *opaque ATTRIBUTE_UNUSED)
+ virStateInhibitCallback callback G_GNUC_UNUSED,
+ void *opaque G_GNUC_UNUSED)
{
DBusConnection *sysbus = NULL;
@@ -384,8 +384,8 @@ nwfilterStateCleanup(void)
static virDrvOpenStatus
nwfilterConnectOpen(virConnectPtr conn,
- virConnectAuthPtr auth ATTRIBUTE_UNUSED,
- virConfPtr conf ATTRIBUTE_UNUSED,
+ virConnectAuthPtr auth G_GNUC_UNUSED,
+ virConfPtr conf G_GNUC_UNUSED,
unsigned int flags)
{
virCheckFlags(VIR_CONNECT_RO, VIR_DRV_OPEN_ERROR);
@@ -409,27 +409,27 @@ nwfilterConnectOpen(virConnectPtr conn,
return VIR_DRV_OPEN_SUCCESS;
}
-static int nwfilterConnectClose(virConnectPtr conn ATTRIBUTE_UNUSED)
+static int nwfilterConnectClose(virConnectPtr conn G_GNUC_UNUSED)
{
return 0;
}
-static int nwfilterConnectIsSecure(virConnectPtr conn ATTRIBUTE_UNUSED)
+static int nwfilterConnectIsSecure(virConnectPtr conn G_GNUC_UNUSED)
{
/* Trivially secure, since always inside the daemon */
return 1;
}
-static int nwfilterConnectIsEncrypted(virConnectPtr conn ATTRIBUTE_UNUSED)
+static int nwfilterConnectIsEncrypted(virConnectPtr conn G_GNUC_UNUSED)
{
/* Not encrypted, but remote driver takes care of that */
return 0;
}
-static int nwfilterConnectIsAlive(virConnectPtr conn ATTRIBUTE_UNUSED)
+static int nwfilterConnectIsAlive(virConnectPtr conn G_GNUC_UNUSED)
{
return 1;
}
diff --git a/src/nwfilter/nwfilter_ebiptables_driver.c
b/src/nwfilter/nwfilter_ebiptables_driver.c
index 32bbf6d05c..50db150151 100644
--- a/src/nwfilter/nwfilter_ebiptables_driver.c
+++ b/src/nwfilter/nwfilter_ebiptables_driver.c
@@ -616,9 +616,9 @@ iptablesLinkTmpRootChainsFW(virFirewallPtr fw,
static void
-iptablesSetupVirtInPostFW(virFirewallPtr fw ATTRIBUTE_UNUSED,
- virFirewallLayer layer ATTRIBUTE_UNUSED,
- const char *ifname ATTRIBUTE_UNUSED)
+iptablesSetupVirtInPostFW(virFirewallPtr fw G_GNUC_UNUSED,
+ virFirewallLayer layer G_GNUC_UNUSED,
+ const char *ifname G_GNUC_UNUSED)
{
virFirewallAddRuleFull(fw, layer,
true, NULL, NULL,
@@ -2805,7 +2805,7 @@ static int
ebtablesRenameTmpSubAndRootChainsQuery(virFirewallPtr fw,
virFirewallLayer layer,
const char *const *lines,
- void *opaque ATTRIBUTE_UNUSED)
+ void *opaque G_GNUC_UNUSED)
{
size_t i;
char newchain[MAX_CHAINNAME_LENGTH];
@@ -3759,8 +3759,8 @@ ebiptablesDriverProbeCtdir(void)
static int
-ebiptablesDriverProbeStateMatchQuery(virFirewallPtr fw ATTRIBUTE_UNUSED,
- virFirewallLayer layer ATTRIBUTE_UNUSED,
+ebiptablesDriverProbeStateMatchQuery(virFirewallPtr fw G_GNUC_UNUSED,
+ virFirewallLayer layer G_GNUC_UNUSED,
const char *const *lines,
void *opaque)
{
diff --git a/src/nwfilter/nwfilter_gentech_driver.c
b/src/nwfilter/nwfilter_gentech_driver.c
index 6d68189d5f..d39f1ecb6d 100644
--- a/src/nwfilter/nwfilter_gentech_driver.c
+++ b/src/nwfilter/nwfilter_gentech_driver.c
@@ -140,7 +140,7 @@ struct printString
static int
-printString(void *payload ATTRIBUTE_UNUSED, const void *name, void *data)
+printString(void *payload G_GNUC_UNUSED, const void *name, void *data)
{
struct printString *ps = data;
diff --git a/src/nwfilter/nwfilter_learnipaddr.c b/src/nwfilter/nwfilter_learnipaddr.c
index 34b8d7fcd9..36bc3b06da 100644
--- a/src/nwfilter/nwfilter_learnipaddr.c
+++ b/src/nwfilter/nwfilter_learnipaddr.c
@@ -307,7 +307,7 @@ virNWFilterHasLearnReq(int ifindex)
static void
-freeLearnReqEntry(void *payload, const void *name ATTRIBUTE_UNUSED)
+freeLearnReqEntry(void *payload, const void *name G_GNUC_UNUSED)
{
virNWFilterIPAddrLearnReqFree(payload);
}
@@ -764,11 +764,11 @@ virNWFilterLearnIPAddress(virNWFilterTechDriverPtr techdriver,
#else
int
-virNWFilterLearnIPAddress(virNWFilterTechDriverPtr techdriver ATTRIBUTE_UNUSED,
- virNWFilterBindingDefPtr binding ATTRIBUTE_UNUSED,
- int ifindex ATTRIBUTE_UNUSED,
- virNWFilterDriverStatePtr driver ATTRIBUTE_UNUSED,
- int howDetect ATTRIBUTE_UNUSED)
+virNWFilterLearnIPAddress(virNWFilterTechDriverPtr techdriver G_GNUC_UNUSED,
+ virNWFilterBindingDefPtr binding G_GNUC_UNUSED,
+ int ifindex G_GNUC_UNUSED,
+ virNWFilterDriverStatePtr driver G_GNUC_UNUSED,
+ int howDetect G_GNUC_UNUSED)
{
virReportError(VIR_ERR_INTERNAL_ERROR, "%s",
_("IP parameter must be given since libvirt "
--
2.19.2