introducing GNUNET_UNUSED macro instead of hard-coding gcc attribute all over the...
authorChristian Grothoff <christian@grothoff.org>
Mon, 28 Nov 2011 16:09:47 +0000 (16:09 +0000)
committerChristian Grothoff <christian@grothoff.org>
Mon, 28 Nov 2011 16:09:47 +0000 (16:09 +0000)
16 files changed:
src/ats/ats_api_performance.c
src/ats/gnunet-service-ats.c
src/ats/gnunet-service-ats_math.c
src/ats/gnunet-service-ats_math.h
src/include/gnunet_common.h
src/transport/gnunet-service-transport_neighbours.c
src/transport/gnunet-service-transport_neighbours.h
src/transport/gnunet-transport-wlan-helper.c
src/transport/gnunet-transport.c
src/transport/plugin_transport_sat_constants.h
src/util/getopt.c
src/vpn/gnunet-daemon-exit.c
src/vpn/gnunet-daemon-vpn-dns.c
src/vpn/gnunet-daemon-vpn-helper.c
src/vpn/gnunet-daemon-vpn.c
src/vpn/gnunet-service-dns.c

index f85d800e4a99f95d753c2f49eb193fc18fdb3e41..9739ac1e5662b46fd5c01f16c8ff206eefe07951 100644 (file)
@@ -167,7 +167,7 @@ struct GNUNET_ATS_PerformanceHandle
 /**
  * Re-establish the connection to the ATS service.
  *
- * @param sh handle to use to re-connect.
+ * @param ph handle to use to re-connect.
  */
 static void
 reconnect (struct GNUNET_ATS_PerformanceHandle *ph);
index 355a44c430a528693422e2c22261599d7fe89b09..ff623594a0401d317d71fa0e034d4ddf0f45b19d 100644 (file)
@@ -43,6 +43,7 @@ struct GNUNET_STATISTICS_Handle *GSA_stats;
  * We have received a 'ClientStartMessage' from a client.  Find out which
  * type of client it is and notify the respective subsystem.
  *
+ * @param cls closure, unused
  * @param client handle to the client
  * @param message the start message
  */
index c5e68b1534a5dff2899f7e62bce57618f33247a5..c38c67789d788d9a711ba3a119c9a1e6ac27f85d 100644 (file)
@@ -19,7 +19,7 @@
 */
 
 /**
- * @file transport/gnunet-service-transport_math.c
+ * @file ats/gnunet-service-transport_math.c
  * @brief automatic transport selection, LP code
  * @author Matthias Wachs
  *
index 9ce9dd2cf353327860b82f8ca5e5787f50628962..2fdceb2c2094d78206fbad63e589ad12b98cfe09 100644 (file)
@@ -19,7 +19,7 @@
 */
 
 /**
- * @file transport/gnunet-service-ats_math.h
+ * @file ats/gnunet-service-ats_math.h
  * @brief common internal definitions for transport service's ats code
  * @author Matthias Wachs
  */
index 69a428bb5cda73503eb0525bc10ff1495b324e3c..d406bcacd0dfb439b9f2205bc2b0ee637001ff96 100644 (file)
  */
 #define GNUNET_PACKED __attribute__((packed))
 
+/**
+ * gcc-ism to document unused arguments
+ */
+#define GNUNET_UNUSED __attribute__((unused))
+
 
 /* ************************ super-general types *********************** */
 
index 95efe44a18a4ae5243607b21c233f66b9b04f04e..6f1aa74317ed722783bbb239a98c5b3519447963 100644 (file)
@@ -1136,6 +1136,7 @@ static void send_outbound_quota (const struct GNUNET_PeerIdentity *target, struc
  * ATS to not use this address anymore (until it is re-validated).
  *
  * @param cls the 'struct GNUNET_HELLO_Address' of the address that was tried
+ * @param target peer to send the message to
  * @param success GNUNET_OK on success
  */
 static void
@@ -1190,11 +1191,13 @@ send_connect_continuation (void *cls, const struct GNUNET_PeerIdentity *target,
   GNUNET_free (cc);
 }
 
+
 /**
  * We tried to switch addresses with an peer already connected. If it failed,
  * we should tell ATS to not use this address anymore (until it is re-validated).
  *
  * @param cls the 'struct NeighbourMapEntry'
+ * @param target peer to send the message to
  * @param success GNUNET_OK on success
  */
 static void
@@ -1291,12 +1294,14 @@ send_switch_address_continuation (void *cls,
   GNUNET_free (cc);
 }
 
+
 /**
  * We tried to send a SESSION_CONNECT message to another peer.  If this
  * succeeded, we change the state.  If it failed, we should tell
  * ATS to not use this address anymore (until it is re-validated).
  *
  * @param cls the 'struct NeighbourMapEntry'
+ * @param target peer to send the message to
  * @param success GNUNET_OK on success
  */
 static void
@@ -1351,6 +1356,7 @@ send_connect_ack_continuation (void *cls,
   GNUNET_free (cc);
 }
 
+
 /**
  * For an existing neighbour record, set the active connection to
  * the given address.
@@ -1971,6 +1977,8 @@ GST_neighbours_keepalive (const struct GNUNET_PeerIdentity *neighbour)
  * to this peer
  *
  * @param neighbour neighbour to keep alive
+ * @param ats performance data
+ * @param ats_count number of entries in ats
  */
 void
 GST_neighbours_keepalive_response (const struct GNUNET_PeerIdentity *neighbour,
index 7a79d511331b1dfb79aa89ada0c22d12babc9b0b..31777343da7ee1fed4ba8155a5c6dc81d7f75a5b 100644 (file)
@@ -129,6 +129,8 @@ GST_neighbours_keepalive (const struct GNUNET_PeerIdentity *neighbour);
  * to this peer
  *
  * @param neighbour neighbour to keep alive
+ * @param ats performance data
+ * @param ats_count number of entries in ats
  */
 void
 GST_neighbours_keepalive_response (const struct GNUNET_PeerIdentity *neighbour,
index 7be72482b1426fe245ae1eb6b84fd018d48ae4c5..53e0efedde2c44bb0fbbc6f5658c27656981d521 100644 (file)
@@ -543,16 +543,17 @@ ieee80211_radiotap_iterator_init (struct ieee80211_radiotap_iterator
 
 
 /**
- * ieee80211_radiotap_iterator_next - return next radiotap parser iterator arg
- * @iterator: radiotap_iterator to move to next arg (if any)
- *
- * Returns: next present arg index on success or negative if no more or error
+ * @brief ieee80211_radiotap_iterator_next - return next radiotap parser iterator arg 
  *
  * This function returns the next radiotap arg index (IEEE80211_RADIOTAP_...)
  * and sets iterator->this_arg to point to the payload for the arg.  It takes
  * care of alignment handling and extended present fields.  interator->this_arg
  * can be changed by the caller.  The args pointed to are in little-endian
  * format.
+ *
+ * @param iterator: radiotap_iterator to move to next arg (if any)
+ *
+ * @return next present arg index on success or negative if no more or error
  */
 static int
 ieee80211_radiotap_iterator_next (struct ieee80211_radiotap_iterator
index 4d2912c344f22b0c7a55d3ea39af2eafd110cd40..4c9e8566cb59d69740ec7d5ef14e2f9252f14527 100644 (file)
@@ -437,7 +437,10 @@ notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer,
  * Function to call with a human-readable format of an address
  *
  * @param cls closure
- * @param address NULL on error, otherwise 0-terminated printable UTF-8 string
+ * @param peer identity of the peer
+ * @param transport name of the plugin
+ * @param addr binary address
+ * @param addrlen number of bytes in addr
  */
 static void
 process_address (void *cls, const struct GNUNET_PeerIdentity *peer,
index bd64c5d2b9be981fb10d93b49475c64cf416852d..b8202817f14b2b44f02ace92b2b9c7bee192b6e9 100644 (file)
@@ -1,6 +1,6 @@
 /*
      This file is part of GNUnet
-     (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Christian Grothoff (and other contributing authors)
+     (C) 2011 Christian Grothoff (and other contributing authors)
 
      GNUnet is free software; you can redistribute it and/or modify
      it under the terms of the GNU General Public License as published
@@ -19,7 +19,7 @@
 */
 
 /**
- * @file transport/plugin_transport_sat_send.h
+ * @file transport/plugin_transport_sat_constants.h
  * @brief header for transport plugin for satellite for send operations
  * @author Christian Rupp
  */
index 317bc074826aa8f0830789cea3ae76bed5092122..6c63cb3398eb455da0ddad5a9216f6b2a066deb6 100644 (file)
@@ -258,7 +258,7 @@ extern pid_t __libc_pid;
    is valid for the getopt call we must make sure that the ARGV passed
    to getopt is that one passed to the process.  */
 static void
-    __attribute__ ((unused)) store_args_and_env (int argc, char *const *argv)
+    GNUNET_UNUSED store_args_and_env (int argc, char *const *argv)
 {
   /* XXX This is no good solution.  We should rather copy the args so
    * that we can compare them later.  But we must not use malloc(3).  */
index 838893882c43fb02427243a40dd6879297157257..e7d904120adb3e7d38d3dae17ac84ef6379152a8 100644 (file)
@@ -170,8 +170,8 @@ struct tunnel_state
  * Function that frees everything from a hashmap
  */
 static int
-free_iterate (void *cls __attribute__ ((unused)), const GNUNET_HashCode * hash
-              __attribute__ ((unused)), void *value)
+free_iterate (void *cls GNUNET_UNUSED, const GNUNET_HashCode * hash
+              GNUNET_UNUSED, void *value)
 {
   GNUNET_free (value);
   return GNUNET_YES;
@@ -182,7 +182,7 @@ free_iterate (void *cls __attribute__ ((unused)), const GNUNET_HashCode * hash
  */
 static void
 cleanup (void *cls
-         __attribute__ ((unused)),
+         GNUNET_UNUSED,
          const struct GNUNET_SCHEDULER_TaskContext *tskctx)
 {
   GNUNET_assert (0 != (tskctx->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN));
@@ -200,10 +200,10 @@ cleanup (void *cls
 
 static void *
 new_tunnel (void *cls
-            __attribute__ ((unused)), struct GNUNET_MESH_Tunnel *tunnel,
+            GNUNET_UNUSED, struct GNUNET_MESH_Tunnel *tunnel,
             const struct GNUNET_PeerIdentity *initiator
-            __attribute__ ((unused)), const struct GNUNET_ATS_Information *ats
-            __attribute__ ((unused)))
+            GNUNET_UNUSED, const struct GNUNET_ATS_Information *ats
+            GNUNET_UNUSED)
 {
   struct tunnel_state *s = GNUNET_malloc (sizeof *s);
 
@@ -215,7 +215,7 @@ new_tunnel (void *cls
 
 static void
 clean_tunnel (void *cls
-              __attribute__ ((unused)), const struct GNUNET_MESH_Tunnel *tunnel,
+              GNUNET_UNUSED, const struct GNUNET_MESH_Tunnel *tunnel,
               void *tunnel_ctx)
 {
   GNUNET_free (tunnel_ctx);
@@ -531,8 +531,8 @@ tcp_from_helper (struct tcp_pkt *tcp, unsigned char *dadr, size_t addrlen,
  * Receive packets from the helper-process
  */
 static void
-message_token (void *cls __attribute__ ((unused)), void *client
-               __attribute__ ((unused)),
+message_token (void *cls GNUNET_UNUSED, void *client
+               GNUNET_UNUSED,
                const struct GNUNET_MessageHeader *message)
 {
   GNUNET_assert (ntohs (message->type) == GNUNET_MESSAGE_TYPE_VPN_HELPER);
@@ -584,7 +584,7 @@ message_token (void *cls __attribute__ ((unused)), void *client
  * @param section name of section in config, equal to hostname
  */
 static void
-read_service_conf (void *cls __attribute__ ((unused)), const char *section)
+read_service_conf (void *cls GNUNET_UNUSED, const char *section)
 {
   if ((strlen (section) < 8) ||
       (0 != strcmp (".gnunet.", section + (strlen (section) - 8))))
@@ -1039,14 +1039,14 @@ prepare_ipv6_packet (size_t len, uint16_t pktlen, void *payload,
  */
 static int
 receive_tcp_service (void *cls
-                     __attribute__ ((unused)),
+                     GNUNET_UNUSED,
                      struct GNUNET_MESH_Tunnel *tunnel, void **tunnel_ctx
-                     __attribute__ ((unused)),
+                     GNUNET_UNUSED,
                      const struct GNUNET_PeerIdentity *sender
-                     __attribute__ ((unused)),
+                     GNUNET_UNUSED,
                      const struct GNUNET_MessageHeader *message,
                      const struct GNUNET_ATS_Information *atsi
-                     __attribute__ ((unused)))
+                     GNUNET_UNUSED)
 {
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Received TCP-Packet\n");
   GNUNET_HashCode *desc = (GNUNET_HashCode *) (message + 1);
@@ -1145,14 +1145,14 @@ receive_tcp_service (void *cls
 
 static int
 receive_tcp_remote (void *cls
-                    __attribute__ ((unused)), struct GNUNET_MESH_Tunnel *tunnel,
+                    GNUNET_UNUSED, struct GNUNET_MESH_Tunnel *tunnel,
                     void **tunnel_ctx
-                    __attribute__ ((unused)),
+                    GNUNET_UNUSED,
                     const struct GNUNET_PeerIdentity *sender
-                    __attribute__ ((unused)),
+                    GNUNET_UNUSED,
                     const struct GNUNET_MessageHeader *message,
                     const struct GNUNET_ATS_Information *atsi
-                    __attribute__ ((unused)))
+                    GNUNET_UNUSED)
 {
   GNUNET_HashCode *desc = (GNUNET_HashCode *) (message + 1);
   struct tcp_pkt *pkt = (struct tcp_pkt *) (desc + 1);
@@ -1221,14 +1221,14 @@ receive_tcp_remote (void *cls
 
 static int
 receive_udp_remote (void *cls
-                    __attribute__ ((unused)), struct GNUNET_MESH_Tunnel *tunnel,
+                    GNUNET_UNUSED, struct GNUNET_MESH_Tunnel *tunnel,
                     void **tunnel_ctx
-                    __attribute__ ((unused)),
+                    GNUNET_UNUSED,
                     const struct GNUNET_PeerIdentity *sender
-                    __attribute__ ((unused)),
+                    GNUNET_UNUSED,
                     const struct GNUNET_MessageHeader *message,
                     const struct GNUNET_ATS_Information *atsi
-                    __attribute__ ((unused)))
+                    GNUNET_UNUSED)
 {
   GNUNET_HashCode *desc = (GNUNET_HashCode *) (message + 1);
   struct udp_pkt *pkt = (struct udp_pkt *) (desc + 1);
@@ -1301,13 +1301,13 @@ receive_udp_remote (void *cls
  */
 static int
 receive_udp_service (void *cls
-                     __attribute__ ((unused)),
+                     GNUNET_UNUSED,
                      struct GNUNET_MESH_Tunnel *tunnel, void **tunnel_ctx,
                      const struct GNUNET_PeerIdentity *sender
-                     __attribute__ ((unused)),
+                     GNUNET_UNUSED,
                      const struct GNUNET_MessageHeader *message,
                      const struct GNUNET_ATS_Information *atsi
-                     __attribute__ ((unused)))
+                     GNUNET_UNUSED)
 {
   GNUNET_HashCode *desc = (GNUNET_HashCode *) (message + 1);
   struct udp_pkt *pkt = (struct udp_pkt *) (desc + 1);
@@ -1463,8 +1463,8 @@ connect_to_mesh ()
  * @param cfg_ configuration
  */
 static void
-run (void *cls, char *const *args __attribute__ ((unused)), const char *cfgfile
-     __attribute__ ((unused)), const struct GNUNET_CONFIGURATION_Handle *cfg_)
+run (void *cls, char *const *args GNUNET_UNUSED, const char *cfgfile
+     GNUNET_UNUSED, const struct GNUNET_CONFIGURATION_Handle *cfg_)
 {
   cfg = cfg_;
 
index 77d9000469f532cd65be29b49eab4f50f8b84449..0e4c88a29ab5453dc74d385536a7ee3cc1ae9221 100644 (file)
@@ -54,7 +54,7 @@ struct GNUNET_CLIENT_TransmitHandle *dns_transmit_handle;
  * {{{
  */
 size_t
-send_query (void *cls __attribute__ ((unused)), size_t size, void *buf)
+send_query (void *cls GNUNET_UNUSED, size_t size, void *buf)
 {
   size_t len;
 
@@ -128,7 +128,7 @@ send_query (void *cls __attribute__ ((unused)), size_t size, void *buf)
  */
 void
 connect_to_service_dns (void *cls
-                        __attribute__ ((unused)),
+                        GNUNET_UNUSED,
                         const struct GNUNET_SCHEDULER_TaskContext *tc)
 {
   conn_task = GNUNET_SCHEDULER_NO_TASK;
@@ -170,7 +170,7 @@ connect_to_service_dns (void *cls
  */
 void
 dns_answer_handler (void *cls
-                    __attribute__ ((unused)),
+                    GNUNET_UNUSED,
                     const struct GNUNET_MessageHeader *msg)
 {
   /* the service disconnected, reconnect after short wait */
index af80764a8d4f364f33bc1e25ed25f7a40179948f..1ffb0f7d864d522e39ad48e8d3dacf65a8de09d8 100644 (file)
@@ -169,7 +169,7 @@ initialize_tunnel_state (int addrlen, struct GNUNET_MESH_TransmitHandle *th)
  */
 void
 helper_write (void *cls
-              __attribute__ ((unused)),
+              GNUNET_UNUSED,
               const struct GNUNET_SCHEDULER_TaskContext *tsdkctx)
 {
   if (tsdkctx->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN)
@@ -321,8 +321,8 @@ helper_write (void *cls
  * Receive packets from the helper-process
  */
 void
-message_token (void *cls __attribute__ ((unused)), void *client
-               __attribute__ ((unused)),
+message_token (void *cls GNUNET_UNUSED, void *client
+               GNUNET_UNUSED,
                const struct GNUNET_MessageHeader *message)
 {
   GNUNET_assert (ntohs (message->type) == GNUNET_MESSAGE_TYPE_VPN_HELPER);
index cc8001eae412119f28ab7389e5e26f443e17b2b4..93ee47e4ec4420da4039d117a94c7209331571bc 100644 (file)
@@ -79,7 +79,7 @@ GNUNET_SCHEDULER_TaskIdentifier shs_task;
  */
 static void
 cleanup (void *cls
-         __attribute__ ((unused)),
+         GNUNET_UNUSED,
          const struct GNUNET_SCHEDULER_TaskContext *tskctx)
 {
   GNUNET_assert (0 != (tskctx->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN));
@@ -169,7 +169,7 @@ address4_mapping_exists (uint32_t addr)
 
 static void
 collect_mappings (void *cls
-                  __attribute__ ((unused)),
+                  GNUNET_UNUSED,
                   const struct GNUNET_SCHEDULER_TaskContext *tc)
 {
   if ((tc->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN) != 0)
@@ -336,7 +336,7 @@ port_in_ports (uint64_t ports, uint16_t port)
 void
 send_pkt_to_peer (void *cls, const struct GNUNET_PeerIdentity *peer,
                   const struct GNUNET_ATS_Information *atsi
-                  __attribute__ ((unused)))
+                  GNUNET_UNUSED)
 {
   /* peer == NULL means that all peers in this request are connected */
   if (peer == NULL)
@@ -857,11 +857,11 @@ add_additional_port (struct map_entry *me, uint16_t port)
 
 static int
 receive_udp_back (void *cls
-                  __attribute__ ((unused)), struct GNUNET_MESH_Tunnel *tunnel,
+                  GNUNET_UNUSED, struct GNUNET_MESH_Tunnel *tunnel,
                   void **tunnel_ctx, const struct GNUNET_PeerIdentity *sender,
                   const struct GNUNET_MessageHeader *message,
                   const struct GNUNET_ATS_Information *atsi
-                  __attribute__ ((unused)))
+                  GNUNET_UNUSED)
 {
   GNUNET_HashCode *desc = (GNUNET_HashCode *) (message + 1);
   struct remote_addr *s = (struct remote_addr *) desc;
@@ -1034,12 +1034,12 @@ receive_udp_back (void *cls
 
 static int
 receive_tcp_back (void *cls
-                  __attribute__ ((unused)), struct GNUNET_MESH_Tunnel *tunnel,
+                  GNUNET_UNUSED, struct GNUNET_MESH_Tunnel *tunnel,
                   void **tunnel_ctx, const struct GNUNET_PeerIdentity *sender
-                  __attribute__ ((unused)),
+                  GNUNET_UNUSED,
                   const struct GNUNET_MessageHeader *message,
                   const struct GNUNET_ATS_Information *atsi
-                  __attribute__ ((unused)))
+                  GNUNET_UNUSED)
 {
   GNUNET_HashCode *desc = (GNUNET_HashCode *) (message + 1);
   struct remote_addr *s = (struct remote_addr *) desc;
@@ -1245,8 +1245,8 @@ cleaner (void *cls, const struct GNUNET_MESH_Tunnel *tunnel, void *tunnel_ctx)
  * @param cfg_ configuration
  */
 static void
-run (void *cls, char *const *args __attribute__ ((unused)), const char *cfgfilep
-     __attribute__ ((unused)), const struct GNUNET_CONFIGURATION_Handle *cfg_)
+run (void *cls, char *const *args GNUNET_UNUSED, const char *cfgfilep
+     GNUNET_UNUSED, const struct GNUNET_CONFIGURATION_Handle *cfg_)
 {
   static const struct GNUNET_MESH_MessageHandler handlers[] = {
     {receive_udp_back, GNUNET_MESSAGE_TYPE_VPN_SERVICE_UDP_BACK, 0},
index c8d790b561847e9591f57cd615c77e2940d651f3..e44405a8ec27d88511ded3a47a7958547e53a5c4 100644 (file)
@@ -168,7 +168,7 @@ client_disconnect (void *cls, struct GNUNET_SERVER_Client *client)
  */
 static void
 hijack (void *cls
-        __attribute__ ((unused)), const struct GNUNET_SCHEDULER_TaskContext *tc)
+        GNUNET_UNUSED, const struct GNUNET_SCHEDULER_TaskContext *tc)
 {
   if (0 != (tc->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN))
     return;
@@ -208,10 +208,10 @@ hijack (void *cls
 
 static void *
 new_tunnel (void *cls
-            __attribute__ ((unused)), struct GNUNET_MESH_Tunnel *tunnel,
+            GNUNET_UNUSED, struct GNUNET_MESH_Tunnel *tunnel,
             const struct GNUNET_PeerIdentity *initiator
-            __attribute__ ((unused)), const struct GNUNET_ATS_Information *ats
-            __attribute__ ((unused)))
+            GNUNET_UNUSED, const struct GNUNET_ATS_Information *ats
+            GNUNET_UNUSED)
 {
   struct tunnel_state *s = GNUNET_malloc (sizeof *s);
 
@@ -223,7 +223,7 @@ new_tunnel (void *cls
 
 static void
 clean_tunnel (void *cls
-              __attribute__ ((unused)), const struct GNUNET_MESH_Tunnel *tunnel,
+              GNUNET_UNUSED, const struct GNUNET_MESH_Tunnel *tunnel,
               void *tunnel_ctx)
 {
   GNUNET_free (tunnel_ctx);
@@ -387,7 +387,7 @@ mesh_send (void *cls, size_t size, void *buf)
 void
 mesh_connect (void *cls, const struct GNUNET_PeerIdentity *peer,
               const struct GNUNET_ATS_Information *atsi
-              __attribute__ ((unused)))
+              GNUNET_UNUSED)
 {
   if (NULL == peer)
     return;
@@ -448,14 +448,14 @@ send_mesh_query (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc)
 
 static int
 receive_mesh_query (void *cls
-                    __attribute__ ((unused)), struct GNUNET_MESH_Tunnel *tunnel,
+                    GNUNET_UNUSED, struct GNUNET_MESH_Tunnel *tunnel,
                     void **ctx
-                    __attribute__ ((unused)),
+                    GNUNET_UNUSED,
                     const struct GNUNET_PeerIdentity *sender
-                    __attribute__ ((unused)),
+                    GNUNET_UNUSED,
                     const struct GNUNET_MessageHeader *message,
                     const struct GNUNET_ATS_Information *atsi
-                    __attribute__ ((unused)))
+                    GNUNET_UNUSED)
 {
   struct dns_pkt *dns = (struct dns_pkt *) (message + 1);
 
@@ -501,13 +501,13 @@ receive_mesh_query (void *cls
 
 static int
 receive_mesh_answer (void *cls
-                     __attribute__ ((unused)),
+                     GNUNET_UNUSED,
                      struct GNUNET_MESH_Tunnel *tunnel, void **ctx
-                     __attribute__ ((unused)),
+                     GNUNET_UNUSED,
                      const struct GNUNET_PeerIdentity *sender,
                      const struct GNUNET_MessageHeader *message,
                      const struct GNUNET_ATS_Information *atsi
-                     __attribute__ ((unused)))
+                     GNUNET_UNUSED)
 {
   /* TODo: size check */
   struct dns_pkt *dns = (struct dns_pkt *) (message + 1);
@@ -750,14 +750,14 @@ send_rev_query (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc)
  */
 static void
 receive_dht (void *cls, struct GNUNET_TIME_Absolute exp
-             __attribute__ ((unused)), const GNUNET_HashCode * key
-             __attribute__ ((unused)),
+             GNUNET_UNUSED, const GNUNET_HashCode * key
+             GNUNET_UNUSED,
              const struct GNUNET_PeerIdentity *get_path
-             __attribute__ ((unused)), unsigned int get_path_length
-             __attribute__ ((unused)),
+             GNUNET_UNUSED, unsigned int get_path_length
+             GNUNET_UNUSED,
              const struct GNUNET_PeerIdentity *put_path
-             __attribute__ ((unused)), unsigned int put_path_length
-             __attribute__ ((unused)), enum GNUNET_BLOCK_Type type, size_t size,
+             GNUNET_UNUSED, unsigned int put_path_length
+             GNUNET_UNUSED, enum GNUNET_BLOCK_Type type, size_t size,
              const void *data)
 {
 
@@ -869,8 +869,8 @@ receive_dht (void *cls, struct GNUNET_TIME_Absolute exp
  */
 static void
 rehijack (void *cls
-          __attribute__ ((unused)), struct GNUNET_SERVER_Client *client,
-          const struct GNUNET_MessageHeader *message __attribute__ ((unused)))
+          GNUNET_UNUSED, struct GNUNET_SERVER_Client *client,
+          const struct GNUNET_MessageHeader *message GNUNET_UNUSED)
 {
   unhijack (dnsoutport);
   GNUNET_SCHEDULER_add_delayed (GNUNET_TIME_UNIT_SECONDS, &hijack, NULL);
@@ -883,7 +883,7 @@ rehijack (void *cls
  */
 static void
 receive_query (void *cls
-               __attribute__ ((unused)), struct GNUNET_SERVER_Client *client,
+               GNUNET_UNUSED, struct GNUNET_SERVER_Client *client,
                const struct GNUNET_MessageHeader *message)
 {
   struct query_packet *pkt = (struct query_packet *) message;
@@ -1232,7 +1232,7 @@ handle_response (struct dns_pkt *dns, struct sockaddr *addr, socklen_t addrlen,
  */
 static void
 read_response6 (void *cls
-                __attribute__ ((unused)),
+                GNUNET_UNUSED,
                 const struct GNUNET_SCHEDULER_TaskContext *tc)
 {
   struct sockaddr_in6 addr;
@@ -1282,7 +1282,7 @@ read_response6 (void *cls
  */
 static void
 read_response (void *cls
-               __attribute__ ((unused)),
+               GNUNET_UNUSED,
                const struct GNUNET_SCHEDULER_TaskContext *tc)
 {
   struct sockaddr_in addr;
@@ -1439,7 +1439,7 @@ handle_response (struct dns_pkt *dns, struct sockaddr *addr, socklen_t addrlen,
  */
 static void
 cleanup_task (void *cls
-              __attribute__ ((unused)),
+              GNUNET_UNUSED,
               const struct GNUNET_SCHEDULER_TaskContext *tc)
 {
   GNUNET_assert (0 != (tc->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN));
@@ -1590,7 +1590,7 @@ publish_name (const char *name, uint64_t ports, uint32_t service_type,
  * @param section the current section
  */
 static void
-publish_iterate (void *cls __attribute__ ((unused)), const char *section)
+publish_iterate (void *cls GNUNET_UNUSED, const char *section)
 {
   char *udp_redirects;
   char *tcp_redirects;
@@ -1666,7 +1666,7 @@ publish_iterate (void *cls __attribute__ ((unused)), const char *section)
  */
 static void
 publish_names (void *cls
-               __attribute__ ((unused)),
+               GNUNET_UNUSED,
                const struct GNUNET_SCHEDULER_TaskContext *tc)
 {
   if (0 != (tc->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN))