diff options
-rw-r--r-- | src/include/gnunet_common.h | 5 | ||||
-rw-r--r-- | src/include/gnunet_connection_lib.h | 4 | ||||
-rw-r--r-- | src/include/gnunet_mesh_service_new.h | 25 | ||||
-rw-r--r-- | src/include/gnunet_resolver_service.h | 2 |
4 files changed, 29 insertions, 7 deletions
diff --git a/src/include/gnunet_common.h b/src/include/gnunet_common.h index b8a667524..f4844821c 100644 --- a/src/include/gnunet_common.h +++ b/src/include/gnunet_common.h | |||
@@ -428,7 +428,7 @@ GNUNET_htonll (unsigned long long n); | |||
428 | * @param length of the string to duplicate | 428 | * @param length of the string to duplicate |
429 | * @return a partial copy of the string including zero-termination | 429 | * @return a partial copy of the string including zero-termination |
430 | */ | 430 | */ |
431 | #define GNUNET_strndup(a,b) GNUNET_xstrndup_(a,b,__FILE__,__LINE__) | 431 | #define GNUNET_strndup(a,length) GNUNET_xstrndup_(a,length,__FILE__,__LINE__) |
432 | 432 | ||
433 | /** | 433 | /** |
434 | * Grow a well-typed (!) array. This is a convenience | 434 | * Grow a well-typed (!) array. This is a convenience |
@@ -577,8 +577,9 @@ GNUNET_xstrdup_ (const char *str, const char *filename, int linenumber); | |||
577 | 577 | ||
578 | /** | 578 | /** |
579 | * Dup partially a string. Don't call GNUNET_xstrndup_ directly. Use the GNUNET_strndup macro. | 579 | * Dup partially a string. Don't call GNUNET_xstrndup_ directly. Use the GNUNET_strndup macro. |
580 | * | ||
580 | * @param str string to duplicate | 581 | * @param str string to duplicate |
581 | * @param len lenght of the string to duplicate | 582 | * @param len length of the string to duplicate |
582 | * @param filename where is this call being made (for debugging) | 583 | * @param filename where is this call being made (for debugging) |
583 | * @param linenumber line where this call is being made (for debugging) | 584 | * @param linenumber line where this call is being made (for debugging) |
584 | * @return the duplicated string | 585 | * @return the duplicated string |
diff --git a/src/include/gnunet_connection_lib.h b/src/include/gnunet_connection_lib.h index 7ee3c109d..3e48d32ea 100644 --- a/src/include/gnunet_connection_lib.h +++ b/src/include/gnunet_connection_lib.h | |||
@@ -341,12 +341,12 @@ GNUNET_CONNECTION_notify_transmit_ready (struct GNUNET_CONNECTION_Handle *sock, | |||
341 | * Cancel the specified transmission-ready | 341 | * Cancel the specified transmission-ready |
342 | * notification. | 342 | * notification. |
343 | * | 343 | * |
344 | * @param h handle for notification to cancel | 344 | * @param th handle for notification to cancel |
345 | */ | 345 | */ |
346 | void | 346 | void |
347 | GNUNET_CONNECTION_notify_transmit_ready_cancel (struct | 347 | GNUNET_CONNECTION_notify_transmit_ready_cancel (struct |
348 | GNUNET_CONNECTION_TransmitHandle | 348 | GNUNET_CONNECTION_TransmitHandle |
349 | *h); | 349 | *th); |
350 | 350 | ||
351 | 351 | ||
352 | /** | 352 | /** |
diff --git a/src/include/gnunet_mesh_service_new.h b/src/include/gnunet_mesh_service_new.h index b9447fe09..4729ae60d 100644 --- a/src/include/gnunet_mesh_service_new.h +++ b/src/include/gnunet_mesh_service_new.h | |||
@@ -56,8 +56,7 @@ struct GNUNET_MESH_Tunnel; | |||
56 | 56 | ||
57 | /** | 57 | /** |
58 | * Functions with this signature are called whenever a message is | 58 | * Functions with this signature are called whenever a message is |
59 | * received or transmitted. | 59 | * received. |
60 | * FIXME: transmitted??? | ||
61 | * | 60 | * |
62 | * @param cls closure (set from GNUNET_MESH_connect) | 61 | * @param cls closure (set from GNUNET_MESH_connect) |
63 | * @param tunnel connection to the other end | 62 | * @param tunnel connection to the other end |
@@ -127,6 +126,26 @@ typedef uint32_t GNUNET_MESH_ApplicationType; | |||
127 | 126 | ||
128 | 127 | ||
129 | /** | 128 | /** |
129 | * Method called whenever another peer has added us to a tunnel | ||
130 | * the other peer initiated. | ||
131 | * | ||
132 | * @param cls closure | ||
133 | * @param tunnel new handle to the tunnel | ||
134 | * @param initiator peer that started 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) | ||
137 | */ | ||
138 | typedef void* (*GNUNET_MESH_InboundTunnelNotificationHandler) (void *cls, | ||
139 | struct GNUNET_MESH_Tunnel * tunnel, | ||
140 | const struct | ||
141 | GNUNET_PeerIdentity * | ||
142 | initiator, | ||
143 | const struct | ||
144 | GNUNET_TRANSPORT_ATS_Information * | ||
145 | atsi); | ||
146 | |||
147 | |||
148 | /** | ||
130 | * Connect to the mesh service. | 149 | * Connect to the mesh service. |
131 | * | 150 | * |
132 | * @param cfg configuration to use | 151 | * @param cfg configuration to use |
@@ -194,12 +213,14 @@ typedef void (*GNUNET_MESH_TunnelConnectHandler) (void *cls, | |||
194 | * and to broadcast). | 213 | * and to broadcast). |
195 | * | 214 | * |
196 | * @param h mesh handle | 215 | * @param h mesh handle |
216 | * @param tunnel_ctx client's tunnel context to associate with the tunnel | ||
197 | * @param connect_handler function to call when peers are actually connected | 217 | * @param connect_handler function to call when peers are actually connected |
198 | * @param disconnect_handler function to call when peers are disconnected | 218 | * @param disconnect_handler function to call when peers are disconnected |
199 | * @param handler_cls closure for connect/disconnect handlers | 219 | * @param handler_cls closure for connect/disconnect handlers |
200 | */ | 220 | */ |
201 | struct GNUNET_MESH_Tunnel * | 221 | struct GNUNET_MESH_Tunnel * |
202 | GNUNET_MESH_tunnel_create (struct GNUNET_MESH_Handle *h, | 222 | GNUNET_MESH_tunnel_create (struct GNUNET_MESH_Handle *h, |
223 | void *tunnel_ctx, | ||
203 | GNUNET_MESH_TunnelConnectHandler connect_handler, | 224 | GNUNET_MESH_TunnelConnectHandler connect_handler, |
204 | GNUNET_MESH_TunnelDisconnectHandler | 225 | GNUNET_MESH_TunnelDisconnectHandler |
205 | disconnect_handler, void *handler_cls); | 226 | disconnect_handler, void *handler_cls); |
diff --git a/src/include/gnunet_resolver_service.h b/src/include/gnunet_resolver_service.h index e55a014e6..ca6544e94 100644 --- a/src/include/gnunet_resolver_service.h +++ b/src/include/gnunet_resolver_service.h | |||
@@ -64,7 +64,7 @@ struct GNUNET_RESOLVER_RequestHandle; | |||
64 | * @param cfg configuration to use | 64 | * @param cfg configuration to use |
65 | */ | 65 | */ |
66 | void | 66 | void |
67 | GNUNET_RESOLVER_connect (const struct GNUNET_CONFIGURATION_Handle *c); | 67 | GNUNET_RESOLVER_connect (const struct GNUNET_CONFIGURATION_Handle *cfg); |
68 | 68 | ||
69 | 69 | ||
70 | /** | 70 | /** |