diff options
author | Christian Grothoff <christian@grothoff.org> | 2011-09-02 14:44:42 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2011-09-02 14:44:42 +0000 |
commit | e1fda8a5d8674328afa61cc50842fdbd2a7044ba (patch) | |
tree | b36e7c638c5b0cb94a693376419959f12d84b84c /src | |
parent | 012cb16a93acbfca1119966d5b4679b99e5c9125 (diff) | |
download | gnunet-e1fda8a5d8674328afa61cc50842fdbd2a7044ba.tar.gz gnunet-e1fda8a5d8674328afa61cc50842fdbd2a7044ba.zip |
doxygen
Diffstat (limited to 'src')
-rw-r--r-- | src/ats/ats_api.c | 2 | ||||
-rw-r--r-- | src/datastore/plugin_datastore_postgres.c | 3 | ||||
-rw-r--r-- | src/fs/fs.h | 4 | ||||
-rw-r--r-- | src/fs/gnunet-service-fs_pr.c | 2 | ||||
-rw-r--r-- | src/fs/gnunet-service-fs_pr.h | 2 | ||||
-rw-r--r-- | src/include/gnunet_mesh_service_new.h | 21 | ||||
-rw-r--r-- | src/mesh/mesh_api_new.c | 80 | ||||
-rw-r--r-- | src/nat/gnunet-nat-server.c | 8 | ||||
-rw-r--r-- | src/nat/nat.c | 16 | ||||
-rw-r--r-- | src/nse/gnunet-nse-profiler.c | 2 | ||||
-rw-r--r-- | src/peerinfo/peerinfo_api.c | 2 | ||||
-rw-r--r-- | src/testing/testing.c | 2 | ||||
-rw-r--r-- | src/transport/gnunet-service-transport_ats.c | 2 | ||||
-rw-r--r-- | src/transport/gnunet-transport-list-connections.c | 2 | ||||
-rw-r--r-- | src/transport/transport-testing.c | 2 | ||||
-rw-r--r-- | src/transport/transport-testing.h | 2 | ||||
-rw-r--r-- | src/util/common_allocation.c | 2 | ||||
-rw-r--r-- | src/util/connection.c | 22 | ||||
-rw-r--r-- | src/util/resolver_api.c | 26 | ||||
-rw-r--r-- | src/util/scheduler.c | 1 |
20 files changed, 101 insertions, 102 deletions
diff --git a/src/ats/ats_api.c b/src/ats/ats_api.c index 42c2f99a4..8a5f23247 100644 --- a/src/ats/ats_api.c +++ b/src/ats/ats_api.c | |||
@@ -256,7 +256,7 @@ update_bandwidth_task (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
256 | /** | 256 | /** |
257 | * Calculate an updated bandwidth assignment and notify. | 257 | * Calculate an updated bandwidth assignment and notify. |
258 | * | 258 | * |
259 | * @param ats handle | 259 | * @param atc handle |
260 | * @param change which allocation record changed? | 260 | * @param change which allocation record changed? |
261 | */ | 261 | */ |
262 | static void | 262 | static void |
diff --git a/src/datastore/plugin_datastore_postgres.c b/src/datastore/plugin_datastore_postgres.c index 4e44107b6..3c37325da 100644 --- a/src/datastore/plugin_datastore_postgres.c +++ b/src/datastore/plugin_datastore_postgres.c | |||
@@ -710,6 +710,8 @@ postgres_plugin_get_key (void *cls, uint64_t offset, | |||
710 | * the given iterator for each of them. | 710 | * the given iterator for each of them. |
711 | * | 711 | * |
712 | * @param cls our "struct Plugin*" | 712 | * @param cls our "struct Plugin*" |
713 | * @param offset offset of the result (modulo num-results); | ||
714 | * specific ordering does not matter for the offset | ||
713 | * @param type entries of which type should be considered? | 715 | * @param type entries of which type should be considered? |
714 | * Use 0 for any type. | 716 | * Use 0 for any type. |
715 | * @param proc function to call on the matching value; | 717 | * @param proc function to call on the matching value; |
@@ -767,7 +769,6 @@ struct ReplCtx | |||
767 | * iterator. | 769 | * iterator. |
768 | * | 770 | * |
769 | * @param cls closure | 771 | * @param cls closure |
770 | * @param next_cls closure to pass to the "next" function. | ||
771 | * @param key key for the content | 772 | * @param key key for the content |
772 | * @param size number of bytes in data | 773 | * @param size number of bytes in data |
773 | * @param data content stored | 774 | * @param data content stored |
diff --git a/src/fs/fs.h b/src/fs/fs.h index 1629af852..ed74850b2 100644 --- a/src/fs/fs.h +++ b/src/fs/fs.h | |||
@@ -871,14 +871,14 @@ GNUNET_FS_unindex_process_hash_ (void *cls, const GNUNET_HashCode * file_id); | |||
871 | * callback. | 871 | * callback. |
872 | * | 872 | * |
873 | * @param pi structure to fill in | 873 | * @param pi structure to fill in |
874 | * @param sc overall publishing context | 874 | * @param pc overall publishing context |
875 | * @param p file information for the file being published | 875 | * @param p file information for the file being published |
876 | * @param offset where in the file are we so far | 876 | * @param offset where in the file are we so far |
877 | * @return value returned from callback | 877 | * @return value returned from callback |
878 | */ | 878 | */ |
879 | void * | 879 | void * |
880 | GNUNET_FS_publish_make_status_ (struct GNUNET_FS_ProgressInfo *pi, | 880 | GNUNET_FS_publish_make_status_ (struct GNUNET_FS_ProgressInfo *pi, |
881 | struct GNUNET_FS_PublishContext *sc, | 881 | struct GNUNET_FS_PublishContext *pc, |
882 | const struct GNUNET_FS_FileInformation *p, | 882 | const struct GNUNET_FS_FileInformation *p, |
883 | uint64_t offset); | 883 | uint64_t offset); |
884 | 884 | ||
diff --git a/src/fs/gnunet-service-fs_pr.c b/src/fs/gnunet-service-fs_pr.c index a1fc60bd9..f63c088c0 100644 --- a/src/fs/gnunet-service-fs_pr.c +++ b/src/fs/gnunet-service-fs_pr.c | |||
@@ -401,7 +401,7 @@ GSF_pending_request_get_data_ (struct GSF_PendingRequest *pr) | |||
401 | * jointly). | 401 | * jointly). |
402 | * | 402 | * |
403 | * @param pra a pending request | 403 | * @param pra a pending request |
404 | * @param pra another pending request | 404 | * @param prb another pending request |
405 | * @return GNUNET_OK if the requests are compatible | 405 | * @return GNUNET_OK if the requests are compatible |
406 | */ | 406 | */ |
407 | int | 407 | int |
diff --git a/src/fs/gnunet-service-fs_pr.h b/src/fs/gnunet-service-fs_pr.h index 03fc047fb..c8ea5b47f 100644 --- a/src/fs/gnunet-service-fs_pr.h +++ b/src/fs/gnunet-service-fs_pr.h | |||
@@ -246,7 +246,7 @@ GSF_pending_request_get_data_ (struct GSF_PendingRequest *pr); | |||
246 | * jointly). | 246 | * jointly). |
247 | * | 247 | * |
248 | * @param pra a pending request | 248 | * @param pra a pending request |
249 | * @param pra another pending request | 249 | * @param prb another pending request |
250 | * @return GNUNET_OK if the requests are compatible | 250 | * @return GNUNET_OK if the requests are compatible |
251 | */ | 251 | */ |
252 | int | 252 | int |
diff --git a/src/include/gnunet_mesh_service_new.h b/src/include/gnunet_mesh_service_new.h index 4729ae60d..7ca53b070 100644 --- a/src/include/gnunet_mesh_service_new.h +++ b/src/include/gnunet_mesh_service_new.h | |||
@@ -135,14 +135,16 @@ typedef uint32_t GNUNET_MESH_ApplicationType; | |||
135 | * @param atsi performance information for the tunnel | 135 | * @param atsi performance information for the tunnel |
136 | * @return initial tunnel context for the tunnel (can be NULL -- that's not an error) | 136 | * @return initial tunnel context for the tunnel (can be NULL -- that's not an error) |
137 | */ | 137 | */ |
138 | typedef void* (*GNUNET_MESH_InboundTunnelNotificationHandler) (void *cls, | 138 | typedef void *(*GNUNET_MESH_InboundTunnelNotificationHandler) (void *cls, |
139 | struct GNUNET_MESH_Tunnel * tunnel, | 139 | struct |
140 | const struct | 140 | GNUNET_MESH_Tunnel |
141 | GNUNET_PeerIdentity * | 141 | * tunnel, |
142 | initiator, | 142 | const struct |
143 | const struct | 143 | GNUNET_PeerIdentity |
144 | GNUNET_TRANSPORT_ATS_Information * | 144 | * initiator, |
145 | atsi); | 145 | const struct |
146 | GNUNET_TRANSPORT_ATS_Information | ||
147 | * atsi); | ||
146 | 148 | ||
147 | 149 | ||
148 | /** | 150 | /** |
@@ -219,8 +221,7 @@ typedef void (*GNUNET_MESH_TunnelConnectHandler) (void *cls, | |||
219 | * @param handler_cls closure for connect/disconnect handlers | 221 | * @param handler_cls closure for connect/disconnect handlers |
220 | */ | 222 | */ |
221 | struct GNUNET_MESH_Tunnel * | 223 | struct GNUNET_MESH_Tunnel * |
222 | GNUNET_MESH_tunnel_create (struct GNUNET_MESH_Handle *h, | 224 | GNUNET_MESH_tunnel_create (struct GNUNET_MESH_Handle *h, void *tunnel_ctx, |
223 | void *tunnel_ctx, | ||
224 | GNUNET_MESH_TunnelConnectHandler connect_handler, | 225 | GNUNET_MESH_TunnelConnectHandler connect_handler, |
225 | GNUNET_MESH_TunnelDisconnectHandler | 226 | GNUNET_MESH_TunnelDisconnectHandler |
226 | disconnect_handler, void *handler_cls); | 227 | disconnect_handler, void *handler_cls); |
diff --git a/src/mesh/mesh_api_new.c b/src/mesh/mesh_api_new.c index b639df812..a2e05e822 100644 --- a/src/mesh/mesh_api_new.c +++ b/src/mesh/mesh_api_new.c | |||
@@ -363,30 +363,30 @@ create_tunnel (struct GNUNET_MESH_Handle *h, MESH_TunnelNumber tid) | |||
363 | static void | 363 | static void |
364 | destroy_tunnel (struct GNUNET_MESH_Handle *h, MESH_TunnelNumber tid) | 364 | destroy_tunnel (struct GNUNET_MESH_Handle *h, MESH_TunnelNumber tid) |
365 | { | 365 | { |
366 | struct GNUNET_MESH_Tunnel *t; | 366 | struct GNUNET_MESH_Tunnel *t; |
367 | struct GNUNET_PeerIdentity pi; | 367 | struct GNUNET_PeerIdentity pi; |
368 | unsigned int i; | 368 | unsigned int i; |
369 | 369 | ||
370 | t = retrieve_tunnel(h, tid); | 370 | t = retrieve_tunnel (h, tid); |
371 | if (NULL == t) | 371 | if (NULL == t) |
372 | { | 372 | { |
373 | GNUNET_break (0); | 373 | GNUNET_break (0); |
374 | return; | ||
375 | } | ||
376 | GNUNET_CONTAINER_DLL_remove (h->tunnels_head, h->tunnels_tail, t); | ||
377 | for (i = 0; i < t->npeers; i++) | ||
378 | { | ||
379 | GNUNET_PEER_resolve(t->peers[i]->id, &pi); | ||
380 | t->disconnect_handler(t->cls, &pi); | ||
381 | GNUNET_PEER_change_rc(t->peers[i]->id, -1); | ||
382 | GNUNET_free (t->peers[i]); | ||
383 | } | ||
384 | h->cleaner(h->cls, t, NULL); /* FIXME ctx? */ | ||
385 | if (0 != t->owner) | ||
386 | GNUNET_PEER_change_rc(t->owner, -1); | ||
387 | GNUNET_free(t->peers); | ||
388 | GNUNET_free(t); | ||
389 | return; | 374 | return; |
375 | } | ||
376 | GNUNET_CONTAINER_DLL_remove (h->tunnels_head, h->tunnels_tail, t); | ||
377 | for (i = 0; i < t->npeers; i++) | ||
378 | { | ||
379 | GNUNET_PEER_resolve (t->peers[i]->id, &pi); | ||
380 | t->disconnect_handler (t->cls, &pi); | ||
381 | GNUNET_PEER_change_rc (t->peers[i]->id, -1); | ||
382 | GNUNET_free (t->peers[i]); | ||
383 | } | ||
384 | h->cleaner (h->cls, t, NULL); /* FIXME ctx? */ | ||
385 | if (0 != t->owner) | ||
386 | GNUNET_PEER_change_rc (t->owner, -1); | ||
387 | GNUNET_free (t->peers); | ||
388 | GNUNET_free (t); | ||
389 | return; | ||
390 | } | 390 | } |
391 | 391 | ||
392 | 392 | ||
@@ -600,7 +600,7 @@ process_tunnel_create (struct GNUNET_MESH_Handle *h, | |||
600 | t->cls = h->cls; | 600 | t->cls = h->cls; |
601 | t->mesh = h; | 601 | t->mesh = h; |
602 | t->tid = tid; | 602 | t->tid = tid; |
603 | GNUNET_CONTAINER_DLL_insert(h->tunnels_head, h->tunnels_tail, t); | 603 | GNUNET_CONTAINER_DLL_insert (h->tunnels_head, h->tunnels_tail, t); |
604 | return; | 604 | return; |
605 | } | 605 | } |
606 | 606 | ||
@@ -615,17 +615,17 @@ static void | |||
615 | process_tunnel_destroy (struct GNUNET_MESH_Handle *h, | 615 | process_tunnel_destroy (struct GNUNET_MESH_Handle *h, |
616 | const struct GNUNET_MESH_TunnelMessage *msg) | 616 | const struct GNUNET_MESH_TunnelMessage *msg) |
617 | { | 617 | { |
618 | struct GNUNET_MESH_Tunnel *t; | 618 | struct GNUNET_MESH_Tunnel *t; |
619 | MESH_TunnelNumber tid; | 619 | MESH_TunnelNumber tid; |
620 | 620 | ||
621 | tid = ntohl (msg->tunnel_id); | 621 | tid = ntohl (msg->tunnel_id); |
622 | t = retrieve_tunnel(h, tid); | 622 | t = retrieve_tunnel (h, tid); |
623 | 623 | ||
624 | t->cls = h->cls; | 624 | t->cls = h->cls; |
625 | t->mesh = h; | 625 | t->mesh = h; |
626 | t->tid = tid; | 626 | t->tid = tid; |
627 | GNUNET_CONTAINER_DLL_insert(h->tunnels_head, h->tunnels_tail, t); | 627 | GNUNET_CONTAINER_DLL_insert (h->tunnels_head, h->tunnels_tail, t); |
628 | return; | 628 | return; |
629 | } | 629 | } |
630 | 630 | ||
631 | 631 | ||
@@ -1101,21 +1101,21 @@ GNUNET_MESH_tunnel_create (struct GNUNET_MESH_Handle *h, | |||
1101 | * @param tun tunnel handle | 1101 | * @param tun tunnel handle |
1102 | */ | 1102 | */ |
1103 | void | 1103 | void |
1104 | GNUNET_MESH_tunnel_destroy (struct GNUNET_MESH_Tunnel *t) | 1104 | GNUNET_MESH_tunnel_destroy (struct GNUNET_MESH_Tunnel *tun) |
1105 | { | 1105 | { |
1106 | struct GNUNET_MESH_Handle *h; | 1106 | struct GNUNET_MESH_Handle *h; |
1107 | struct GNUNET_MESH_TunnelMessage msg; | 1107 | struct GNUNET_MESH_TunnelMessage msg; |
1108 | 1108 | ||
1109 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "mesh: Destroying tunnel\n"); | 1109 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "mesh: Destroying tunnel\n"); |
1110 | h = t->mesh; | 1110 | h = tun->mesh; |
1111 | 1111 | ||
1112 | if (0 != t->owner) | 1112 | if (0 != tun->owner) |
1113 | GNUNET_PEER_change_rc (t->owner, -1); | 1113 | GNUNET_PEER_change_rc (tun->owner, -1); |
1114 | 1114 | ||
1115 | msg.header.type = htons (GNUNET_MESSAGE_TYPE_MESH_LOCAL_TUNNEL_DESTROY); | 1115 | msg.header.type = htons (GNUNET_MESSAGE_TYPE_MESH_LOCAL_TUNNEL_DESTROY); |
1116 | msg.header.size = htons (sizeof (struct GNUNET_MESH_TunnelMessage)); | 1116 | msg.header.size = htons (sizeof (struct GNUNET_MESH_TunnelMessage)); |
1117 | msg.tunnel_id = htonl (t->tid); | 1117 | msg.tunnel_id = htonl (tun->tid); |
1118 | GNUNET_free (t); | 1118 | GNUNET_free (tun); |
1119 | send_packet (h, &msg.header); | 1119 | send_packet (h, &msg.header); |
1120 | } | 1120 | } |
1121 | 1121 | ||
diff --git a/src/nat/gnunet-nat-server.c b/src/nat/gnunet-nat-server.c index 5e2390f35..bb637235d 100644 --- a/src/nat/gnunet-nat-server.c +++ b/src/nat/gnunet-nat-server.c | |||
@@ -94,7 +94,7 @@ struct TcpContext | |||
94 | * Task called by the scheduler once we can do the TCP send | 94 | * Task called by the scheduler once we can do the TCP send |
95 | * (or once we failed to connect...). | 95 | * (or once we failed to connect...). |
96 | * | 96 | * |
97 | * @param ctx the 'struct TcpContext' | 97 | * @param cls the 'struct TcpContext' |
98 | * @param tc scheduler context | 98 | * @param tc scheduler context |
99 | */ | 99 | */ |
100 | static void | 100 | static void |
@@ -123,7 +123,7 @@ tcp_send (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
123 | * Try to send 'data' to the | 123 | * Try to send 'data' to the |
124 | * IP 'dst_ipv4' at port 'dport' via TCP. | 124 | * IP 'dst_ipv4' at port 'dport' via TCP. |
125 | * | 125 | * |
126 | * @param dst_ivp4 target IP | 126 | * @param dst_ipv4 target IP |
127 | * @param dport target port | 127 | * @param dport target port |
128 | * @param data data to send | 128 | * @param data data to send |
129 | */ | 129 | */ |
@@ -170,7 +170,7 @@ try_send_tcp (uint32_t dst_ipv4, uint16_t dport, uint16_t data) | |||
170 | * Try to send 'data' to the | 170 | * Try to send 'data' to the |
171 | * IP 'dst_ipv4' at port 'dport' via UDP. | 171 | * IP 'dst_ipv4' at port 'dport' via UDP. |
172 | * | 172 | * |
173 | * @param dst_ivp4 target IP | 173 | * @param dst_ipv4 target IP |
174 | * @param dport target port | 174 | * @param dport target port |
175 | * @param data data to send | 175 | * @param data data to send |
176 | */ | 176 | */ |
@@ -238,7 +238,7 @@ test (void *cls, struct GNUNET_SERVER_Client *client, | |||
238 | /** | 238 | /** |
239 | * Task run during shutdown. | 239 | * Task run during shutdown. |
240 | * | 240 | * |
241 | * @param ctx unused | 241 | * @param cls unused |
242 | * @param tc scheduler context | 242 | * @param tc scheduler context |
243 | */ | 243 | */ |
244 | static void | 244 | static void |
diff --git a/src/nat/nat.c b/src/nat/nat.c index 891613fea..925838496 100644 --- a/src/nat/nat.c +++ b/src/nat/nat.c | |||
@@ -369,7 +369,7 @@ start_gnunet_nat_server (struct GNUNET_NAT_Handle *h); | |||
369 | * Remove all addresses from the list of 'local' addresses | 369 | * Remove all addresses from the list of 'local' addresses |
370 | * that originated from the given source. | 370 | * that originated from the given source. |
371 | * | 371 | * |
372 | * @param plugin the plugin | 372 | * @param h handle to NAT |
373 | * @param src source that identifies addresses to remove | 373 | * @param src source that identifies addresses to remove |
374 | */ | 374 | */ |
375 | static void | 375 | static void |
@@ -398,7 +398,7 @@ remove_from_address_list_by_source (struct GNUNET_NAT_Handle *h, | |||
398 | * Add the given address to the list of 'local' addresses, thereby | 398 | * Add the given address to the list of 'local' addresses, thereby |
399 | * making it a 'legal' address for this peer to have. | 399 | * making it a 'legal' address for this peer to have. |
400 | * | 400 | * |
401 | * @param plugin the plugin | 401 | * @param h handle to NAT |
402 | * @param src where did the local address originate from? | 402 | * @param src where did the local address originate from? |
403 | * @param arg the address, some 'struct sockaddr' | 403 | * @param arg the address, some 'struct sockaddr' |
404 | * @param arg_size number of bytes in arg | 404 | * @param arg_size number of bytes in arg |
@@ -432,7 +432,7 @@ add_to_address_list_as_is (struct GNUNET_NAT_Handle *h, | |||
432 | * port number in the process to the advertised port and possibly | 432 | * port number in the process to the advertised port and possibly |
433 | * also to zero (if we have the gnunet-helper-nat-server). | 433 | * also to zero (if we have the gnunet-helper-nat-server). |
434 | * | 434 | * |
435 | * @param plugin the plugin | 435 | * @param h handle to NAT |
436 | * @param src where did the local address originate from? | 436 | * @param src where did the local address originate from? |
437 | * @param arg the address, some 'struct sockaddr' | 437 | * @param arg the address, some 'struct sockaddr' |
438 | * @param arg_size number of bytes in arg | 438 | * @param arg_size number of bytes in arg |
@@ -483,10 +483,10 @@ add_to_address_list (struct GNUNET_NAT_Handle *h, enum LocalAddressSource src, | |||
483 | * Add the given IP address to the list of 'local' addresses, thereby | 483 | * Add the given IP address to the list of 'local' addresses, thereby |
484 | * making it a 'legal' address for this peer to have. | 484 | * making it a 'legal' address for this peer to have. |
485 | * | 485 | * |
486 | * @param plugin the plugin | 486 | * @param h handle to NAT |
487 | * @param src where did the local address originate from? | 487 | * @param src where did the local address originate from? |
488 | * @param arg the address, some 'struct in_addr' or 'struct in6_addr' | 488 | * @param addr the address, some 'struct in_addr' or 'struct in6_addr' |
489 | * @param arg_size number of bytes in arg | 489 | * @param addrlen number of bytes in addr |
490 | */ | 490 | */ |
491 | static void | 491 | static void |
492 | add_ip_to_address_list (struct GNUNET_NAT_Handle *h, | 492 | add_ip_to_address_list (struct GNUNET_NAT_Handle *h, |
@@ -1035,8 +1035,8 @@ add_from_bind (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
1035 | * @param adv_port advertised port (port we are either bound to or that our OS | 1035 | * @param adv_port advertised port (port we are either bound to or that our OS |
1036 | * locally performs redirection from to our bound port). | 1036 | * locally performs redirection from to our bound port). |
1037 | * @param num_addrs number of addresses in 'addrs' | 1037 | * @param num_addrs number of addresses in 'addrs' |
1038 | * @param addr the local address packets should be redirected to | 1038 | * @param addrs the local addresses packets should be redirected to |
1039 | * @param addrlen actual lenght of the address | 1039 | * @param addrlens actual lengths of the addresses |
1040 | * @param address_callback function to call everytime the public IP address changes | 1040 | * @param address_callback function to call everytime the public IP address changes |
1041 | * @param reversal_callback function to call if someone wants connection reversal from us | 1041 | * @param reversal_callback function to call if someone wants connection reversal from us |
1042 | * @param callback_cls closure for callbacks | 1042 | * @param callback_cls closure for callbacks |
diff --git a/src/nse/gnunet-nse-profiler.c b/src/nse/gnunet-nse-profiler.c index 4879c5916..0df6ddf7d 100644 --- a/src/nse/gnunet-nse-profiler.c +++ b/src/nse/gnunet-nse-profiler.c | |||
@@ -18,7 +18,7 @@ | |||
18 | Boston, MA 02111-1307, USA. | 18 | Boston, MA 02111-1307, USA. |
19 | */ | 19 | */ |
20 | /** | 20 | /** |
21 | * @file nse/nse-profiler.c | 21 | * @file nse/gnunet-nse-profiler.c |
22 | * | 22 | * |
23 | * @brief Profiling driver for the network size estimation service. | 23 | * @brief Profiling driver for the network size estimation service. |
24 | * Generally, the profiler starts a given number of peers, | 24 | * Generally, the profiler starts a given number of peers, |
diff --git a/src/peerinfo/peerinfo_api.c b/src/peerinfo/peerinfo_api.c index 345375819..28828f3a3 100644 --- a/src/peerinfo/peerinfo_api.c +++ b/src/peerinfo/peerinfo_api.c | |||
@@ -204,7 +204,7 @@ reconnect (struct GNUNET_PEERINFO_Handle *h); | |||
204 | * Task scheduled to re-try connecting to the peerinfo service. | 204 | * Task scheduled to re-try connecting to the peerinfo service. |
205 | * | 205 | * |
206 | * @param cls the 'struct GNUNET_PEERINFO_Handle' | 206 | * @param cls the 'struct GNUNET_PEERINFO_Handle' |
207 | * @param ts scheduler context | 207 | * @param tc scheduler context |
208 | */ | 208 | */ |
209 | static void | 209 | static void |
210 | reconnect_task (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | 210 | reconnect_task (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) |
diff --git a/src/testing/testing.c b/src/testing/testing.c index 5eaa0a12b..ecd6140a6 100644 --- a/src/testing/testing.c +++ b/src/testing/testing.c | |||
@@ -1546,8 +1546,6 @@ GNUNET_TESTING_daemon_restart (struct GNUNET_TESTING_Daemon *d, | |||
1546 | * @param timeout how long to wait for process for shutdown to complete | 1546 | * @param timeout how long to wait for process for shutdown to complete |
1547 | * @param cb function called once the daemon was stopped | 1547 | * @param cb function called once the daemon was stopped |
1548 | * @param cb_cls closure for cb | 1548 | * @param cb_cls closure for cb |
1549 | * @param delete_files GNUNET_YES to remove files, GNUNET_NO | ||
1550 | * to leave them | ||
1551 | * @param allow_restart GNUNET_YES to restart peer later (using this API) | 1549 | * @param allow_restart GNUNET_YES to restart peer later (using this API) |
1552 | * GNUNET_NO to kill off and clean up for good | 1550 | * GNUNET_NO to kill off and clean up for good |
1553 | */ | 1551 | */ |
diff --git a/src/transport/gnunet-service-transport_ats.c b/src/transport/gnunet-service-transport_ats.c index 87aa34bf4..220fe522b 100644 --- a/src/transport/gnunet-service-transport_ats.c +++ b/src/transport/gnunet-service-transport_ats.c | |||
@@ -19,7 +19,7 @@ | |||
19 | */ | 19 | */ |
20 | 20 | ||
21 | /** | 21 | /** |
22 | * @file transport/transport_ats.c | 22 | * @file transport/gnunet-service-transport_ats.c |
23 | * @brief automatic transport selection | 23 | * @brief automatic transport selection |
24 | * @author Matthias Wachs | 24 | * @author Matthias Wachs |
25 | * | 25 | * |
diff --git a/src/transport/gnunet-transport-list-connections.c b/src/transport/gnunet-transport-list-connections.c index d31d2febb..0542a5cd9 100644 --- a/src/transport/gnunet-transport-list-connections.c +++ b/src/transport/gnunet-transport-list-connections.c | |||
@@ -19,7 +19,7 @@ | |||
19 | */ | 19 | */ |
20 | 20 | ||
21 | /** | 21 | /** |
22 | * @file core/gnunet-transport-list-connections.c | 22 | * @file transport/gnunet-transport-list-connections.c |
23 | * | 23 | * |
24 | * @brief Print all known address information about other peers. | 24 | * @brief Print all known address information about other peers. |
25 | * | 25 | * |
diff --git a/src/transport/transport-testing.c b/src/transport/transport-testing.c index e604c5961..21856c8f2 100644 --- a/src/transport/transport-testing.c +++ b/src/transport/transport-testing.c | |||
@@ -19,7 +19,7 @@ | |||
19 | */ | 19 | */ |
20 | 20 | ||
21 | /** | 21 | /** |
22 | * @file transport_testing.c | 22 | * @file transport-testing.c |
23 | * @brief testing lib for transport service | 23 | * @brief testing lib for transport service |
24 | * | 24 | * |
25 | * @author Matthias Wachs | 25 | * @author Matthias Wachs |
diff --git a/src/transport/transport-testing.h b/src/transport/transport-testing.h index 80eae3630..a5c1b529a 100644 --- a/src/transport/transport-testing.h +++ b/src/transport/transport-testing.h | |||
@@ -19,7 +19,7 @@ | |||
19 | */ | 19 | */ |
20 | 20 | ||
21 | /** | 21 | /** |
22 | * @file transport_testing.h | 22 | * @file transport-testing.h |
23 | * @brief testing lib for transport service | 23 | * @brief testing lib for transport service |
24 | * | 24 | * |
25 | * @author Matthias Wachs | 25 | * @author Matthias Wachs |
diff --git a/src/util/common_allocation.c b/src/util/common_allocation.c index 71aa15add..ad74727bc 100644 --- a/src/util/common_allocation.c +++ b/src/util/common_allocation.c | |||
@@ -222,7 +222,7 @@ GNUNET_xstrdup_ (const char *str, const char *filename, int linenumber) | |||
222 | * Dup partially a string (same semantics as strndup). | 222 | * Dup partially a string (same semantics as strndup). |
223 | * | 223 | * |
224 | * @param str the string to dup | 224 | * @param str the string to dup |
225 | * @param len the lenght of the string to dup | 225 | * @param len the length of the string to dup |
226 | * @param filename where in the code was the call to GNUNET_strndup | 226 | * @param filename where in the code was the call to GNUNET_strndup |
227 | * @param linenumber where in the code was the call to GNUNET_strndup | 227 | * @param linenumber where in the code was the call to GNUNET_strndup |
228 | * @return strndup(str,len) | 228 | * @return strndup(str,len) |
diff --git a/src/util/connection.c b/src/util/connection.c index 8639d2416..2c32923c2 100644 --- a/src/util/connection.c +++ b/src/util/connection.c | |||
@@ -1685,28 +1685,28 @@ GNUNET_CONNECTION_notify_transmit_ready (struct GNUNET_CONNECTION_Handle *sock, | |||
1685 | void | 1685 | void |
1686 | GNUNET_CONNECTION_notify_transmit_ready_cancel (struct | 1686 | GNUNET_CONNECTION_notify_transmit_ready_cancel (struct |
1687 | GNUNET_CONNECTION_TransmitHandle | 1687 | GNUNET_CONNECTION_TransmitHandle |
1688 | *h) | 1688 | *th) |
1689 | { | 1689 | { |
1690 | GNUNET_assert (h->notify_ready != NULL); | 1690 | GNUNET_assert (th->notify_ready != NULL); |
1691 | if (0 != (h->sh->ccs & COCO_TRANSMIT_READY)) | 1691 | if (0 != (th->sh->ccs & COCO_TRANSMIT_READY)) |
1692 | { | 1692 | { |
1693 | #if DEBUG_CONNECTION | 1693 | #if DEBUG_CONNECTION |
1694 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1694 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1695 | "notify_transmit_ready_cancel cancels timeout_task (%p)\n", h); | 1695 | "notify_transmit_ready_cancel cancels timeout_task (%p)\n", th); |
1696 | #endif | 1696 | #endif |
1697 | GNUNET_SCHEDULER_cancel (h->timeout_task); | 1697 | GNUNET_SCHEDULER_cancel (th->timeout_task); |
1698 | h->timeout_task = GNUNET_SCHEDULER_NO_TASK; | 1698 | th->timeout_task = GNUNET_SCHEDULER_NO_TASK; |
1699 | h->sh->ccs -= COCO_TRANSMIT_READY; | 1699 | th->sh->ccs -= COCO_TRANSMIT_READY; |
1700 | } | 1700 | } |
1701 | else | 1701 | else |
1702 | { | 1702 | { |
1703 | if (h->sh->write_task != GNUNET_SCHEDULER_NO_TASK) | 1703 | if (th->sh->write_task != GNUNET_SCHEDULER_NO_TASK) |
1704 | { | 1704 | { |
1705 | GNUNET_SCHEDULER_cancel (h->sh->write_task); | 1705 | GNUNET_SCHEDULER_cancel (th->sh->write_task); |
1706 | h->sh->write_task = GNUNET_SCHEDULER_NO_TASK; | 1706 | th->sh->write_task = GNUNET_SCHEDULER_NO_TASK; |
1707 | } | 1707 | } |
1708 | } | 1708 | } |
1709 | h->notify_ready = NULL; | 1709 | th->notify_ready = NULL; |
1710 | } | 1710 | } |
1711 | 1711 | ||
1712 | /* end of connection.c */ | 1712 | /* end of connection.c */ |
diff --git a/src/util/resolver_api.c b/src/util/resolver_api.c index 69c49d1e8..87b7bbd46 100644 --- a/src/util/resolver_api.c +++ b/src/util/resolver_api.c | |||
@@ -52,7 +52,7 @@ static const char *loopback[] = { | |||
52 | /** | 52 | /** |
53 | * Configuration. | 53 | * Configuration. |
54 | */ | 54 | */ |
55 | static const struct GNUNET_CONFIGURATION_Handle *cfg; | 55 | static const struct GNUNET_CONFIGURATION_Handle *resolver_cfg; |
56 | 56 | ||
57 | /** | 57 | /** |
58 | * Our connection to the resolver service, created on-demand, but then | 58 | * Our connection to the resolver service, created on-demand, but then |
@@ -172,7 +172,7 @@ struct GNUNET_RESOLVER_RequestHandle | |||
172 | * (or equivalent). | 172 | * (or equivalent). |
173 | */ | 173 | */ |
174 | static void | 174 | static void |
175 | check_config (const struct GNUNET_CONFIGURATION_Handle *cfg) | 175 | check_config () |
176 | { | 176 | { |
177 | char *hostname; | 177 | char *hostname; |
178 | unsigned int i; | 178 | unsigned int i; |
@@ -191,8 +191,8 @@ check_config (const struct GNUNET_CONFIGURATION_Handle *cfg) | |||
191 | v6.sin6_len = sizeof (v6); | 191 | v6.sin6_len = sizeof (v6); |
192 | #endif | 192 | #endif |
193 | if (GNUNET_OK != | 193 | if (GNUNET_OK != |
194 | GNUNET_CONFIGURATION_get_value_string (cfg, "resolver", "HOSTNAME", | 194 | GNUNET_CONFIGURATION_get_value_string (resolver_cfg, "resolver", |
195 | &hostname)) | 195 | "HOSTNAME", &hostname)) |
196 | { | 196 | { |
197 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | 197 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, |
198 | _("Must specify `%s' for `%s' in configuration!\n"), "HOSTNAME", | 198 | _("Must specify `%s' for `%s' in configuration!\n"), "HOSTNAME", |
@@ -224,15 +224,15 @@ check_config (const struct GNUNET_CONFIGURATION_Handle *cfg) | |||
224 | /** | 224 | /** |
225 | * Create the connection to the resolver service. | 225 | * Create the connection to the resolver service. |
226 | * | 226 | * |
227 | * @param c configuration to use | 227 | * @param cfg configuration to use |
228 | */ | 228 | */ |
229 | void | 229 | void |
230 | GNUNET_RESOLVER_connect (const struct GNUNET_CONFIGURATION_Handle *c) | 230 | GNUNET_RESOLVER_connect (const struct GNUNET_CONFIGURATION_Handle *cfg) |
231 | { | 231 | { |
232 | GNUNET_assert (NULL != c); | 232 | GNUNET_assert (NULL != cfg); |
233 | check_config (c); | ||
234 | backoff = GNUNET_TIME_UNIT_MILLISECONDS; | 233 | backoff = GNUNET_TIME_UNIT_MILLISECONDS; |
235 | cfg = c; | 234 | resolver_cfg = cfg; |
235 | check_config (); | ||
236 | } | 236 | } |
237 | 237 | ||
238 | 238 | ||
@@ -324,8 +324,6 @@ reconnect (); | |||
324 | 324 | ||
325 | /** | 325 | /** |
326 | * Process pending requests to the resolver. | 326 | * Process pending requests to the resolver. |
327 | * | ||
328 | * @param h handle to the resolver | ||
329 | */ | 327 | */ |
330 | static void | 328 | static void |
331 | process_requests (); | 329 | process_requests (); |
@@ -654,7 +652,7 @@ reconnect_task (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
654 | #if DEBUG_RESOLVER | 652 | #if DEBUG_RESOLVER |
655 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Trying to connect to DNS service\n"); | 653 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Trying to connect to DNS service\n"); |
656 | #endif | 654 | #endif |
657 | client = GNUNET_CLIENT_connect ("resolver", cfg); | 655 | client = GNUNET_CLIENT_connect ("resolver", resolver_cfg); |
658 | if (NULL == client) | 656 | if (NULL == client) |
659 | { | 657 | { |
660 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 658 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
@@ -703,7 +701,7 @@ reconnect () | |||
703 | "Will try to connect to DNS service in %llu ms\n", | 701 | "Will try to connect to DNS service in %llu ms\n", |
704 | (unsigned long long) backoff.rel_value); | 702 | (unsigned long long) backoff.rel_value); |
705 | #endif | 703 | #endif |
706 | GNUNET_assert (NULL != cfg); | 704 | GNUNET_assert (NULL != resolver_cfg); |
707 | r_task = GNUNET_SCHEDULER_add_delayed (backoff, &reconnect_task, NULL); | 705 | r_task = GNUNET_SCHEDULER_add_delayed (backoff, &reconnect_task, NULL); |
708 | backoff = GNUNET_TIME_relative_multiply (backoff, 2); | 706 | backoff = GNUNET_TIME_relative_multiply (backoff, 2); |
709 | } | 707 | } |
@@ -823,7 +821,7 @@ GNUNET_RESOLVER_hostname_get (const struct sockaddr *sa, socklen_t salen, | |||
823 | { | 821 | { |
824 | struct GNUNET_RESOLVER_RequestHandle *rh; | 822 | struct GNUNET_RESOLVER_RequestHandle *rh; |
825 | 823 | ||
826 | check_config (cfg); | 824 | check_config (); |
827 | rh = GNUNET_malloc (sizeof (struct GNUNET_RESOLVER_RequestHandle) + salen); | 825 | rh = GNUNET_malloc (sizeof (struct GNUNET_RESOLVER_RequestHandle) + salen); |
828 | rh->name_callback = callback; | 826 | rh->name_callback = callback; |
829 | rh->cls = cls; | 827 | rh->cls = cls; |
diff --git a/src/util/scheduler.c b/src/util/scheduler.c index 0ed48e793..e2f6700e4 100644 --- a/src/util/scheduler.c +++ b/src/util/scheduler.c | |||
@@ -260,6 +260,7 @@ static void *scheduler_select_cls; | |||
260 | * Sets the select function to use in the scheduler (scheduler_select). | 260 | * Sets the select function to use in the scheduler (scheduler_select). |
261 | * | 261 | * |
262 | * @param new_select new select function to use | 262 | * @param new_select new select function to use |
263 | * @param new_select_cls closure for 'new_select' | ||
263 | * @return previously used select function, NULL for default | 264 | * @return previously used select function, NULL for default |
264 | */ | 265 | */ |
265 | void | 266 | void |