diff options
author | Christian Grothoff <christian@grothoff.org> | 2011-11-28 16:09:47 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2011-11-28 16:09:47 +0000 |
commit | 4917fb20a07aa3221683c8a2112c514f44594350 (patch) | |
tree | 3584e6988f6bcddd19ea9d77c040e02d659a79c9 /src/vpn | |
parent | 636b3202c2ea8ebc6dd51a90c839a2e495ea0d27 (diff) | |
download | gnunet-4917fb20a07aa3221683c8a2112c514f44594350.tar.gz gnunet-4917fb20a07aa3221683c8a2112c514f44594350.zip |
introducing GNUNET_UNUSED macro instead of hard-coding gcc attribute all over the place; also some further documentation fixes
Diffstat (limited to 'src/vpn')
-rw-r--r-- | src/vpn/gnunet-daemon-exit.c | 54 | ||||
-rw-r--r-- | src/vpn/gnunet-daemon-vpn-dns.c | 6 | ||||
-rw-r--r-- | src/vpn/gnunet-daemon-vpn-helper.c | 6 | ||||
-rw-r--r-- | src/vpn/gnunet-daemon-vpn.c | 20 | ||||
-rw-r--r-- | src/vpn/gnunet-service-dns.c | 54 |
5 files changed, 70 insertions, 70 deletions
diff --git a/src/vpn/gnunet-daemon-exit.c b/src/vpn/gnunet-daemon-exit.c index 838893882..e7d904120 100644 --- a/src/vpn/gnunet-daemon-exit.c +++ b/src/vpn/gnunet-daemon-exit.c | |||
@@ -170,8 +170,8 @@ struct tunnel_state | |||
170 | * Function that frees everything from a hashmap | 170 | * Function that frees everything from a hashmap |
171 | */ | 171 | */ |
172 | static int | 172 | static int |
173 | free_iterate (void *cls __attribute__ ((unused)), const GNUNET_HashCode * hash | 173 | free_iterate (void *cls GNUNET_UNUSED, const GNUNET_HashCode * hash |
174 | __attribute__ ((unused)), void *value) | 174 | GNUNET_UNUSED, void *value) |
175 | { | 175 | { |
176 | GNUNET_free (value); | 176 | GNUNET_free (value); |
177 | return GNUNET_YES; | 177 | return GNUNET_YES; |
@@ -182,7 +182,7 @@ free_iterate (void *cls __attribute__ ((unused)), const GNUNET_HashCode * hash | |||
182 | */ | 182 | */ |
183 | static void | 183 | static void |
184 | cleanup (void *cls | 184 | cleanup (void *cls |
185 | __attribute__ ((unused)), | 185 | GNUNET_UNUSED, |
186 | const struct GNUNET_SCHEDULER_TaskContext *tskctx) | 186 | const struct GNUNET_SCHEDULER_TaskContext *tskctx) |
187 | { | 187 | { |
188 | GNUNET_assert (0 != (tskctx->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN)); | 188 | GNUNET_assert (0 != (tskctx->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN)); |
@@ -200,10 +200,10 @@ cleanup (void *cls | |||
200 | 200 | ||
201 | static void * | 201 | static void * |
202 | new_tunnel (void *cls | 202 | new_tunnel (void *cls |
203 | __attribute__ ((unused)), struct GNUNET_MESH_Tunnel *tunnel, | 203 | GNUNET_UNUSED, struct GNUNET_MESH_Tunnel *tunnel, |
204 | const struct GNUNET_PeerIdentity *initiator | 204 | const struct GNUNET_PeerIdentity *initiator |
205 | __attribute__ ((unused)), const struct GNUNET_ATS_Information *ats | 205 | GNUNET_UNUSED, const struct GNUNET_ATS_Information *ats |
206 | __attribute__ ((unused))) | 206 | GNUNET_UNUSED) |
207 | { | 207 | { |
208 | struct tunnel_state *s = GNUNET_malloc (sizeof *s); | 208 | struct tunnel_state *s = GNUNET_malloc (sizeof *s); |
209 | 209 | ||
@@ -215,7 +215,7 @@ new_tunnel (void *cls | |||
215 | 215 | ||
216 | static void | 216 | static void |
217 | clean_tunnel (void *cls | 217 | clean_tunnel (void *cls |
218 | __attribute__ ((unused)), const struct GNUNET_MESH_Tunnel *tunnel, | 218 | GNUNET_UNUSED, const struct GNUNET_MESH_Tunnel *tunnel, |
219 | void *tunnel_ctx) | 219 | void *tunnel_ctx) |
220 | { | 220 | { |
221 | GNUNET_free (tunnel_ctx); | 221 | GNUNET_free (tunnel_ctx); |
@@ -531,8 +531,8 @@ tcp_from_helper (struct tcp_pkt *tcp, unsigned char *dadr, size_t addrlen, | |||
531 | * Receive packets from the helper-process | 531 | * Receive packets from the helper-process |
532 | */ | 532 | */ |
533 | static void | 533 | static void |
534 | message_token (void *cls __attribute__ ((unused)), void *client | 534 | message_token (void *cls GNUNET_UNUSED, void *client |
535 | __attribute__ ((unused)), | 535 | GNUNET_UNUSED, |
536 | const struct GNUNET_MessageHeader *message) | 536 | const struct GNUNET_MessageHeader *message) |
537 | { | 537 | { |
538 | GNUNET_assert (ntohs (message->type) == GNUNET_MESSAGE_TYPE_VPN_HELPER); | 538 | GNUNET_assert (ntohs (message->type) == GNUNET_MESSAGE_TYPE_VPN_HELPER); |
@@ -584,7 +584,7 @@ message_token (void *cls __attribute__ ((unused)), void *client | |||
584 | * @param section name of section in config, equal to hostname | 584 | * @param section name of section in config, equal to hostname |
585 | */ | 585 | */ |
586 | static void | 586 | static void |
587 | read_service_conf (void *cls __attribute__ ((unused)), const char *section) | 587 | read_service_conf (void *cls GNUNET_UNUSED, const char *section) |
588 | { | 588 | { |
589 | if ((strlen (section) < 8) || | 589 | if ((strlen (section) < 8) || |
590 | (0 != strcmp (".gnunet.", section + (strlen (section) - 8)))) | 590 | (0 != strcmp (".gnunet.", section + (strlen (section) - 8)))) |
@@ -1039,14 +1039,14 @@ prepare_ipv6_packet (size_t len, uint16_t pktlen, void *payload, | |||
1039 | */ | 1039 | */ |
1040 | static int | 1040 | static int |
1041 | receive_tcp_service (void *cls | 1041 | receive_tcp_service (void *cls |
1042 | __attribute__ ((unused)), | 1042 | GNUNET_UNUSED, |
1043 | struct GNUNET_MESH_Tunnel *tunnel, void **tunnel_ctx | 1043 | struct GNUNET_MESH_Tunnel *tunnel, void **tunnel_ctx |
1044 | __attribute__ ((unused)), | 1044 | GNUNET_UNUSED, |
1045 | const struct GNUNET_PeerIdentity *sender | 1045 | const struct GNUNET_PeerIdentity *sender |
1046 | __attribute__ ((unused)), | 1046 | GNUNET_UNUSED, |
1047 | const struct GNUNET_MessageHeader *message, | 1047 | const struct GNUNET_MessageHeader *message, |
1048 | const struct GNUNET_ATS_Information *atsi | 1048 | const struct GNUNET_ATS_Information *atsi |
1049 | __attribute__ ((unused))) | 1049 | GNUNET_UNUSED) |
1050 | { | 1050 | { |
1051 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Received TCP-Packet\n"); | 1051 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Received TCP-Packet\n"); |
1052 | GNUNET_HashCode *desc = (GNUNET_HashCode *) (message + 1); | 1052 | GNUNET_HashCode *desc = (GNUNET_HashCode *) (message + 1); |
@@ -1145,14 +1145,14 @@ receive_tcp_service (void *cls | |||
1145 | 1145 | ||
1146 | static int | 1146 | static int |
1147 | receive_tcp_remote (void *cls | 1147 | receive_tcp_remote (void *cls |
1148 | __attribute__ ((unused)), struct GNUNET_MESH_Tunnel *tunnel, | 1148 | GNUNET_UNUSED, struct GNUNET_MESH_Tunnel *tunnel, |
1149 | void **tunnel_ctx | 1149 | void **tunnel_ctx |
1150 | __attribute__ ((unused)), | 1150 | GNUNET_UNUSED, |
1151 | const struct GNUNET_PeerIdentity *sender | 1151 | const struct GNUNET_PeerIdentity *sender |
1152 | __attribute__ ((unused)), | 1152 | GNUNET_UNUSED, |
1153 | const struct GNUNET_MessageHeader *message, | 1153 | const struct GNUNET_MessageHeader *message, |
1154 | const struct GNUNET_ATS_Information *atsi | 1154 | const struct GNUNET_ATS_Information *atsi |
1155 | __attribute__ ((unused))) | 1155 | GNUNET_UNUSED) |
1156 | { | 1156 | { |
1157 | GNUNET_HashCode *desc = (GNUNET_HashCode *) (message + 1); | 1157 | GNUNET_HashCode *desc = (GNUNET_HashCode *) (message + 1); |
1158 | struct tcp_pkt *pkt = (struct tcp_pkt *) (desc + 1); | 1158 | struct tcp_pkt *pkt = (struct tcp_pkt *) (desc + 1); |
@@ -1221,14 +1221,14 @@ receive_tcp_remote (void *cls | |||
1221 | 1221 | ||
1222 | static int | 1222 | static int |
1223 | receive_udp_remote (void *cls | 1223 | receive_udp_remote (void *cls |
1224 | __attribute__ ((unused)), struct GNUNET_MESH_Tunnel *tunnel, | 1224 | GNUNET_UNUSED, struct GNUNET_MESH_Tunnel *tunnel, |
1225 | void **tunnel_ctx | 1225 | void **tunnel_ctx |
1226 | __attribute__ ((unused)), | 1226 | GNUNET_UNUSED, |
1227 | const struct GNUNET_PeerIdentity *sender | 1227 | const struct GNUNET_PeerIdentity *sender |
1228 | __attribute__ ((unused)), | 1228 | GNUNET_UNUSED, |
1229 | const struct GNUNET_MessageHeader *message, | 1229 | const struct GNUNET_MessageHeader *message, |
1230 | const struct GNUNET_ATS_Information *atsi | 1230 | const struct GNUNET_ATS_Information *atsi |
1231 | __attribute__ ((unused))) | 1231 | GNUNET_UNUSED) |
1232 | { | 1232 | { |
1233 | GNUNET_HashCode *desc = (GNUNET_HashCode *) (message + 1); | 1233 | GNUNET_HashCode *desc = (GNUNET_HashCode *) (message + 1); |
1234 | struct udp_pkt *pkt = (struct udp_pkt *) (desc + 1); | 1234 | struct udp_pkt *pkt = (struct udp_pkt *) (desc + 1); |
@@ -1301,13 +1301,13 @@ receive_udp_remote (void *cls | |||
1301 | */ | 1301 | */ |
1302 | static int | 1302 | static int |
1303 | receive_udp_service (void *cls | 1303 | receive_udp_service (void *cls |
1304 | __attribute__ ((unused)), | 1304 | GNUNET_UNUSED, |
1305 | struct GNUNET_MESH_Tunnel *tunnel, void **tunnel_ctx, | 1305 | struct GNUNET_MESH_Tunnel *tunnel, void **tunnel_ctx, |
1306 | const struct GNUNET_PeerIdentity *sender | 1306 | const struct GNUNET_PeerIdentity *sender |
1307 | __attribute__ ((unused)), | 1307 | GNUNET_UNUSED, |
1308 | const struct GNUNET_MessageHeader *message, | 1308 | const struct GNUNET_MessageHeader *message, |
1309 | const struct GNUNET_ATS_Information *atsi | 1309 | const struct GNUNET_ATS_Information *atsi |
1310 | __attribute__ ((unused))) | 1310 | GNUNET_UNUSED) |
1311 | { | 1311 | { |
1312 | GNUNET_HashCode *desc = (GNUNET_HashCode *) (message + 1); | 1312 | GNUNET_HashCode *desc = (GNUNET_HashCode *) (message + 1); |
1313 | struct udp_pkt *pkt = (struct udp_pkt *) (desc + 1); | 1313 | struct udp_pkt *pkt = (struct udp_pkt *) (desc + 1); |
@@ -1463,8 +1463,8 @@ connect_to_mesh () | |||
1463 | * @param cfg_ configuration | 1463 | * @param cfg_ configuration |
1464 | */ | 1464 | */ |
1465 | static void | 1465 | static void |
1466 | run (void *cls, char *const *args __attribute__ ((unused)), const char *cfgfile | 1466 | run (void *cls, char *const *args GNUNET_UNUSED, const char *cfgfile |
1467 | __attribute__ ((unused)), const struct GNUNET_CONFIGURATION_Handle *cfg_) | 1467 | GNUNET_UNUSED, const struct GNUNET_CONFIGURATION_Handle *cfg_) |
1468 | { | 1468 | { |
1469 | cfg = cfg_; | 1469 | cfg = cfg_; |
1470 | 1470 | ||
diff --git a/src/vpn/gnunet-daemon-vpn-dns.c b/src/vpn/gnunet-daemon-vpn-dns.c index 77d900046..0e4c88a29 100644 --- a/src/vpn/gnunet-daemon-vpn-dns.c +++ b/src/vpn/gnunet-daemon-vpn-dns.c | |||
@@ -54,7 +54,7 @@ struct GNUNET_CLIENT_TransmitHandle *dns_transmit_handle; | |||
54 | * {{{ | 54 | * {{{ |
55 | */ | 55 | */ |
56 | size_t | 56 | size_t |
57 | send_query (void *cls __attribute__ ((unused)), size_t size, void *buf) | 57 | send_query (void *cls GNUNET_UNUSED, size_t size, void *buf) |
58 | { | 58 | { |
59 | size_t len; | 59 | size_t len; |
60 | 60 | ||
@@ -128,7 +128,7 @@ send_query (void *cls __attribute__ ((unused)), size_t size, void *buf) | |||
128 | */ | 128 | */ |
129 | void | 129 | void |
130 | connect_to_service_dns (void *cls | 130 | connect_to_service_dns (void *cls |
131 | __attribute__ ((unused)), | 131 | GNUNET_UNUSED, |
132 | const struct GNUNET_SCHEDULER_TaskContext *tc) | 132 | const struct GNUNET_SCHEDULER_TaskContext *tc) |
133 | { | 133 | { |
134 | conn_task = GNUNET_SCHEDULER_NO_TASK; | 134 | conn_task = GNUNET_SCHEDULER_NO_TASK; |
@@ -170,7 +170,7 @@ connect_to_service_dns (void *cls | |||
170 | */ | 170 | */ |
171 | void | 171 | void |
172 | dns_answer_handler (void *cls | 172 | dns_answer_handler (void *cls |
173 | __attribute__ ((unused)), | 173 | GNUNET_UNUSED, |
174 | const struct GNUNET_MessageHeader *msg) | 174 | const struct GNUNET_MessageHeader *msg) |
175 | { | 175 | { |
176 | /* the service disconnected, reconnect after short wait */ | 176 | /* the service disconnected, reconnect after short wait */ |
diff --git a/src/vpn/gnunet-daemon-vpn-helper.c b/src/vpn/gnunet-daemon-vpn-helper.c index af80764a8..1ffb0f7d8 100644 --- a/src/vpn/gnunet-daemon-vpn-helper.c +++ b/src/vpn/gnunet-daemon-vpn-helper.c | |||
@@ -169,7 +169,7 @@ initialize_tunnel_state (int addrlen, struct GNUNET_MESH_TransmitHandle *th) | |||
169 | */ | 169 | */ |
170 | void | 170 | void |
171 | helper_write (void *cls | 171 | helper_write (void *cls |
172 | __attribute__ ((unused)), | 172 | GNUNET_UNUSED, |
173 | const struct GNUNET_SCHEDULER_TaskContext *tsdkctx) | 173 | const struct GNUNET_SCHEDULER_TaskContext *tsdkctx) |
174 | { | 174 | { |
175 | if (tsdkctx->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN) | 175 | if (tsdkctx->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN) |
@@ -321,8 +321,8 @@ helper_write (void *cls | |||
321 | * Receive packets from the helper-process | 321 | * Receive packets from the helper-process |
322 | */ | 322 | */ |
323 | void | 323 | void |
324 | message_token (void *cls __attribute__ ((unused)), void *client | 324 | message_token (void *cls GNUNET_UNUSED, void *client |
325 | __attribute__ ((unused)), | 325 | GNUNET_UNUSED, |
326 | const struct GNUNET_MessageHeader *message) | 326 | const struct GNUNET_MessageHeader *message) |
327 | { | 327 | { |
328 | GNUNET_assert (ntohs (message->type) == GNUNET_MESSAGE_TYPE_VPN_HELPER); | 328 | GNUNET_assert (ntohs (message->type) == GNUNET_MESSAGE_TYPE_VPN_HELPER); |
diff --git a/src/vpn/gnunet-daemon-vpn.c b/src/vpn/gnunet-daemon-vpn.c index cc8001eae..93ee47e4e 100644 --- a/src/vpn/gnunet-daemon-vpn.c +++ b/src/vpn/gnunet-daemon-vpn.c | |||
@@ -79,7 +79,7 @@ GNUNET_SCHEDULER_TaskIdentifier shs_task; | |||
79 | */ | 79 | */ |
80 | static void | 80 | static void |
81 | cleanup (void *cls | 81 | cleanup (void *cls |
82 | __attribute__ ((unused)), | 82 | GNUNET_UNUSED, |
83 | const struct GNUNET_SCHEDULER_TaskContext *tskctx) | 83 | const struct GNUNET_SCHEDULER_TaskContext *tskctx) |
84 | { | 84 | { |
85 | GNUNET_assert (0 != (tskctx->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN)); | 85 | GNUNET_assert (0 != (tskctx->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN)); |
@@ -169,7 +169,7 @@ address4_mapping_exists (uint32_t addr) | |||
169 | 169 | ||
170 | static void | 170 | static void |
171 | collect_mappings (void *cls | 171 | collect_mappings (void *cls |
172 | __attribute__ ((unused)), | 172 | GNUNET_UNUSED, |
173 | const struct GNUNET_SCHEDULER_TaskContext *tc) | 173 | const struct GNUNET_SCHEDULER_TaskContext *tc) |
174 | { | 174 | { |
175 | if ((tc->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN) != 0) | 175 | if ((tc->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN) != 0) |
@@ -336,7 +336,7 @@ port_in_ports (uint64_t ports, uint16_t port) | |||
336 | void | 336 | void |
337 | send_pkt_to_peer (void *cls, const struct GNUNET_PeerIdentity *peer, | 337 | send_pkt_to_peer (void *cls, const struct GNUNET_PeerIdentity *peer, |
338 | const struct GNUNET_ATS_Information *atsi | 338 | const struct GNUNET_ATS_Information *atsi |
339 | __attribute__ ((unused))) | 339 | GNUNET_UNUSED) |
340 | { | 340 | { |
341 | /* peer == NULL means that all peers in this request are connected */ | 341 | /* peer == NULL means that all peers in this request are connected */ |
342 | if (peer == NULL) | 342 | if (peer == NULL) |
@@ -857,11 +857,11 @@ add_additional_port (struct map_entry *me, uint16_t port) | |||
857 | 857 | ||
858 | static int | 858 | static int |
859 | receive_udp_back (void *cls | 859 | receive_udp_back (void *cls |
860 | __attribute__ ((unused)), struct GNUNET_MESH_Tunnel *tunnel, | 860 | GNUNET_UNUSED, struct GNUNET_MESH_Tunnel *tunnel, |
861 | void **tunnel_ctx, const struct GNUNET_PeerIdentity *sender, | 861 | void **tunnel_ctx, const struct GNUNET_PeerIdentity *sender, |
862 | const struct GNUNET_MessageHeader *message, | 862 | const struct GNUNET_MessageHeader *message, |
863 | const struct GNUNET_ATS_Information *atsi | 863 | const struct GNUNET_ATS_Information *atsi |
864 | __attribute__ ((unused))) | 864 | GNUNET_UNUSED) |
865 | { | 865 | { |
866 | GNUNET_HashCode *desc = (GNUNET_HashCode *) (message + 1); | 866 | GNUNET_HashCode *desc = (GNUNET_HashCode *) (message + 1); |
867 | struct remote_addr *s = (struct remote_addr *) desc; | 867 | struct remote_addr *s = (struct remote_addr *) desc; |
@@ -1034,12 +1034,12 @@ receive_udp_back (void *cls | |||
1034 | 1034 | ||
1035 | static int | 1035 | static int |
1036 | receive_tcp_back (void *cls | 1036 | receive_tcp_back (void *cls |
1037 | __attribute__ ((unused)), struct GNUNET_MESH_Tunnel *tunnel, | 1037 | GNUNET_UNUSED, struct GNUNET_MESH_Tunnel *tunnel, |
1038 | void **tunnel_ctx, const struct GNUNET_PeerIdentity *sender | 1038 | void **tunnel_ctx, const struct GNUNET_PeerIdentity *sender |
1039 | __attribute__ ((unused)), | 1039 | GNUNET_UNUSED, |
1040 | const struct GNUNET_MessageHeader *message, | 1040 | const struct GNUNET_MessageHeader *message, |
1041 | const struct GNUNET_ATS_Information *atsi | 1041 | const struct GNUNET_ATS_Information *atsi |
1042 | __attribute__ ((unused))) | 1042 | GNUNET_UNUSED) |
1043 | { | 1043 | { |
1044 | GNUNET_HashCode *desc = (GNUNET_HashCode *) (message + 1); | 1044 | GNUNET_HashCode *desc = (GNUNET_HashCode *) (message + 1); |
1045 | struct remote_addr *s = (struct remote_addr *) desc; | 1045 | struct remote_addr *s = (struct remote_addr *) desc; |
@@ -1245,8 +1245,8 @@ cleaner (void *cls, const struct GNUNET_MESH_Tunnel *tunnel, void *tunnel_ctx) | |||
1245 | * @param cfg_ configuration | 1245 | * @param cfg_ configuration |
1246 | */ | 1246 | */ |
1247 | static void | 1247 | static void |
1248 | run (void *cls, char *const *args __attribute__ ((unused)), const char *cfgfilep | 1248 | run (void *cls, char *const *args GNUNET_UNUSED, const char *cfgfilep |
1249 | __attribute__ ((unused)), const struct GNUNET_CONFIGURATION_Handle *cfg_) | 1249 | GNUNET_UNUSED, const struct GNUNET_CONFIGURATION_Handle *cfg_) |
1250 | { | 1250 | { |
1251 | static const struct GNUNET_MESH_MessageHandler handlers[] = { | 1251 | static const struct GNUNET_MESH_MessageHandler handlers[] = { |
1252 | {receive_udp_back, GNUNET_MESSAGE_TYPE_VPN_SERVICE_UDP_BACK, 0}, | 1252 | {receive_udp_back, GNUNET_MESSAGE_TYPE_VPN_SERVICE_UDP_BACK, 0}, |
diff --git a/src/vpn/gnunet-service-dns.c b/src/vpn/gnunet-service-dns.c index c8d790b56..e44405a8e 100644 --- a/src/vpn/gnunet-service-dns.c +++ b/src/vpn/gnunet-service-dns.c | |||
@@ -168,7 +168,7 @@ client_disconnect (void *cls, struct GNUNET_SERVER_Client *client) | |||
168 | */ | 168 | */ |
169 | static void | 169 | static void |
170 | hijack (void *cls | 170 | hijack (void *cls |
171 | __attribute__ ((unused)), const struct GNUNET_SCHEDULER_TaskContext *tc) | 171 | GNUNET_UNUSED, const struct GNUNET_SCHEDULER_TaskContext *tc) |
172 | { | 172 | { |
173 | if (0 != (tc->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN)) | 173 | if (0 != (tc->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN)) |
174 | return; | 174 | return; |
@@ -208,10 +208,10 @@ hijack (void *cls | |||
208 | 208 | ||
209 | static void * | 209 | static void * |
210 | new_tunnel (void *cls | 210 | new_tunnel (void *cls |
211 | __attribute__ ((unused)), struct GNUNET_MESH_Tunnel *tunnel, | 211 | GNUNET_UNUSED, struct GNUNET_MESH_Tunnel *tunnel, |
212 | const struct GNUNET_PeerIdentity *initiator | 212 | const struct GNUNET_PeerIdentity *initiator |
213 | __attribute__ ((unused)), const struct GNUNET_ATS_Information *ats | 213 | GNUNET_UNUSED, const struct GNUNET_ATS_Information *ats |
214 | __attribute__ ((unused))) | 214 | GNUNET_UNUSED) |
215 | { | 215 | { |
216 | struct tunnel_state *s = GNUNET_malloc (sizeof *s); | 216 | struct tunnel_state *s = GNUNET_malloc (sizeof *s); |
217 | 217 | ||
@@ -223,7 +223,7 @@ new_tunnel (void *cls | |||
223 | 223 | ||
224 | static void | 224 | static void |
225 | clean_tunnel (void *cls | 225 | clean_tunnel (void *cls |
226 | __attribute__ ((unused)), const struct GNUNET_MESH_Tunnel *tunnel, | 226 | GNUNET_UNUSED, const struct GNUNET_MESH_Tunnel *tunnel, |
227 | void *tunnel_ctx) | 227 | void *tunnel_ctx) |
228 | { | 228 | { |
229 | GNUNET_free (tunnel_ctx); | 229 | GNUNET_free (tunnel_ctx); |
@@ -387,7 +387,7 @@ mesh_send (void *cls, size_t size, void *buf) | |||
387 | void | 387 | void |
388 | mesh_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | 388 | mesh_connect (void *cls, const struct GNUNET_PeerIdentity *peer, |
389 | const struct GNUNET_ATS_Information *atsi | 389 | const struct GNUNET_ATS_Information *atsi |
390 | __attribute__ ((unused))) | 390 | GNUNET_UNUSED) |
391 | { | 391 | { |
392 | if (NULL == peer) | 392 | if (NULL == peer) |
393 | return; | 393 | return; |
@@ -448,14 +448,14 @@ send_mesh_query (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
448 | 448 | ||
449 | static int | 449 | static int |
450 | receive_mesh_query (void *cls | 450 | receive_mesh_query (void *cls |
451 | __attribute__ ((unused)), struct GNUNET_MESH_Tunnel *tunnel, | 451 | GNUNET_UNUSED, struct GNUNET_MESH_Tunnel *tunnel, |
452 | void **ctx | 452 | void **ctx |
453 | __attribute__ ((unused)), | 453 | GNUNET_UNUSED, |
454 | const struct GNUNET_PeerIdentity *sender | 454 | const struct GNUNET_PeerIdentity *sender |
455 | __attribute__ ((unused)), | 455 | GNUNET_UNUSED, |
456 | const struct GNUNET_MessageHeader *message, | 456 | const struct GNUNET_MessageHeader *message, |
457 | const struct GNUNET_ATS_Information *atsi | 457 | const struct GNUNET_ATS_Information *atsi |
458 | __attribute__ ((unused))) | 458 | GNUNET_UNUSED) |
459 | { | 459 | { |
460 | struct dns_pkt *dns = (struct dns_pkt *) (message + 1); | 460 | struct dns_pkt *dns = (struct dns_pkt *) (message + 1); |
461 | 461 | ||
@@ -501,13 +501,13 @@ receive_mesh_query (void *cls | |||
501 | 501 | ||
502 | static int | 502 | static int |
503 | receive_mesh_answer (void *cls | 503 | receive_mesh_answer (void *cls |
504 | __attribute__ ((unused)), | 504 | GNUNET_UNUSED, |
505 | struct GNUNET_MESH_Tunnel *tunnel, void **ctx | 505 | struct GNUNET_MESH_Tunnel *tunnel, void **ctx |
506 | __attribute__ ((unused)), | 506 | GNUNET_UNUSED, |
507 | const struct GNUNET_PeerIdentity *sender, | 507 | const struct GNUNET_PeerIdentity *sender, |
508 | const struct GNUNET_MessageHeader *message, | 508 | const struct GNUNET_MessageHeader *message, |
509 | const struct GNUNET_ATS_Information *atsi | 509 | const struct GNUNET_ATS_Information *atsi |
510 | __attribute__ ((unused))) | 510 | GNUNET_UNUSED) |
511 | { | 511 | { |
512 | /* TODo: size check */ | 512 | /* TODo: size check */ |
513 | struct dns_pkt *dns = (struct dns_pkt *) (message + 1); | 513 | struct dns_pkt *dns = (struct dns_pkt *) (message + 1); |
@@ -750,14 +750,14 @@ send_rev_query (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
750 | */ | 750 | */ |
751 | static void | 751 | static void |
752 | receive_dht (void *cls, struct GNUNET_TIME_Absolute exp | 752 | receive_dht (void *cls, struct GNUNET_TIME_Absolute exp |
753 | __attribute__ ((unused)), const GNUNET_HashCode * key | 753 | GNUNET_UNUSED, const GNUNET_HashCode * key |
754 | __attribute__ ((unused)), | 754 | GNUNET_UNUSED, |
755 | const struct GNUNET_PeerIdentity *get_path | 755 | const struct GNUNET_PeerIdentity *get_path |
756 | __attribute__ ((unused)), unsigned int get_path_length | 756 | GNUNET_UNUSED, unsigned int get_path_length |
757 | __attribute__ ((unused)), | 757 | GNUNET_UNUSED, |
758 | const struct GNUNET_PeerIdentity *put_path | 758 | const struct GNUNET_PeerIdentity *put_path |
759 | __attribute__ ((unused)), unsigned int put_path_length | 759 | GNUNET_UNUSED, unsigned int put_path_length |
760 | __attribute__ ((unused)), enum GNUNET_BLOCK_Type type, size_t size, | 760 | GNUNET_UNUSED, enum GNUNET_BLOCK_Type type, size_t size, |
761 | const void *data) | 761 | const void *data) |
762 | { | 762 | { |
763 | 763 | ||
@@ -869,8 +869,8 @@ receive_dht (void *cls, struct GNUNET_TIME_Absolute exp | |||
869 | */ | 869 | */ |
870 | static void | 870 | static void |
871 | rehijack (void *cls | 871 | rehijack (void *cls |
872 | __attribute__ ((unused)), struct GNUNET_SERVER_Client *client, | 872 | GNUNET_UNUSED, struct GNUNET_SERVER_Client *client, |
873 | const struct GNUNET_MessageHeader *message __attribute__ ((unused))) | 873 | const struct GNUNET_MessageHeader *message GNUNET_UNUSED) |
874 | { | 874 | { |
875 | unhijack (dnsoutport); | 875 | unhijack (dnsoutport); |
876 | GNUNET_SCHEDULER_add_delayed (GNUNET_TIME_UNIT_SECONDS, &hijack, NULL); | 876 | GNUNET_SCHEDULER_add_delayed (GNUNET_TIME_UNIT_SECONDS, &hijack, NULL); |
@@ -883,7 +883,7 @@ rehijack (void *cls | |||
883 | */ | 883 | */ |
884 | static void | 884 | static void |
885 | receive_query (void *cls | 885 | receive_query (void *cls |
886 | __attribute__ ((unused)), struct GNUNET_SERVER_Client *client, | 886 | GNUNET_UNUSED, struct GNUNET_SERVER_Client *client, |
887 | const struct GNUNET_MessageHeader *message) | 887 | const struct GNUNET_MessageHeader *message) |
888 | { | 888 | { |
889 | struct query_packet *pkt = (struct query_packet *) message; | 889 | struct query_packet *pkt = (struct query_packet *) message; |
@@ -1232,7 +1232,7 @@ handle_response (struct dns_pkt *dns, struct sockaddr *addr, socklen_t addrlen, | |||
1232 | */ | 1232 | */ |
1233 | static void | 1233 | static void |
1234 | read_response6 (void *cls | 1234 | read_response6 (void *cls |
1235 | __attribute__ ((unused)), | 1235 | GNUNET_UNUSED, |
1236 | const struct GNUNET_SCHEDULER_TaskContext *tc) | 1236 | const struct GNUNET_SCHEDULER_TaskContext *tc) |
1237 | { | 1237 | { |
1238 | struct sockaddr_in6 addr; | 1238 | struct sockaddr_in6 addr; |
@@ -1282,7 +1282,7 @@ read_response6 (void *cls | |||
1282 | */ | 1282 | */ |
1283 | static void | 1283 | static void |
1284 | read_response (void *cls | 1284 | read_response (void *cls |
1285 | __attribute__ ((unused)), | 1285 | GNUNET_UNUSED, |
1286 | const struct GNUNET_SCHEDULER_TaskContext *tc) | 1286 | const struct GNUNET_SCHEDULER_TaskContext *tc) |
1287 | { | 1287 | { |
1288 | struct sockaddr_in addr; | 1288 | struct sockaddr_in addr; |
@@ -1439,7 +1439,7 @@ handle_response (struct dns_pkt *dns, struct sockaddr *addr, socklen_t addrlen, | |||
1439 | */ | 1439 | */ |
1440 | static void | 1440 | static void |
1441 | cleanup_task (void *cls | 1441 | cleanup_task (void *cls |
1442 | __attribute__ ((unused)), | 1442 | GNUNET_UNUSED, |
1443 | const struct GNUNET_SCHEDULER_TaskContext *tc) | 1443 | const struct GNUNET_SCHEDULER_TaskContext *tc) |
1444 | { | 1444 | { |
1445 | GNUNET_assert (0 != (tc->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN)); | 1445 | 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, | |||
1590 | * @param section the current section | 1590 | * @param section the current section |
1591 | */ | 1591 | */ |
1592 | static void | 1592 | static void |
1593 | publish_iterate (void *cls __attribute__ ((unused)), const char *section) | 1593 | publish_iterate (void *cls GNUNET_UNUSED, const char *section) |
1594 | { | 1594 | { |
1595 | char *udp_redirects; | 1595 | char *udp_redirects; |
1596 | char *tcp_redirects; | 1596 | char *tcp_redirects; |
@@ -1666,7 +1666,7 @@ publish_iterate (void *cls __attribute__ ((unused)), const char *section) | |||
1666 | */ | 1666 | */ |
1667 | static void | 1667 | static void |
1668 | publish_names (void *cls | 1668 | publish_names (void *cls |
1669 | __attribute__ ((unused)), | 1669 | GNUNET_UNUSED, |
1670 | const struct GNUNET_SCHEDULER_TaskContext *tc) | 1670 | const struct GNUNET_SCHEDULER_TaskContext *tc) |
1671 | { | 1671 | { |
1672 | if (0 != (tc->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN)) | 1672 | if (0 != (tc->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN)) |