breaking stuff
authorChristian Grothoff <christian@grothoff.org>
Fri, 2 Sep 2011 14:44:08 +0000 (14:44 +0000)
committerChristian Grothoff <christian@grothoff.org>
Fri, 2 Sep 2011 14:44:08 +0000 (14:44 +0000)
src/include/gnunet_common.h
src/include/gnunet_connection_lib.h
src/include/gnunet_mesh_service_new.h
src/include/gnunet_resolver_service.h

index b8a667524c6b08e8a9115c38002514204914a549..f4844821ca029c699d4867168df4baf85d06bc98 100644 (file)
@@ -428,7 +428,7 @@ GNUNET_htonll (unsigned long long n);
  * @param length of the string to duplicate
  * @return a partial copy of the string including zero-termination
  */
-#define GNUNET_strndup(a,b) GNUNET_xstrndup_(a,b,__FILE__,__LINE__)
+#define GNUNET_strndup(a,length) GNUNET_xstrndup_(a,length,__FILE__,__LINE__)
 
 /**
  * Grow a well-typed (!) array.  This is a convenience
@@ -577,8 +577,9 @@ GNUNET_xstrdup_ (const char *str, const char *filename, int linenumber);
 
 /**
  * Dup partially a string. Don't call GNUNET_xstrndup_ directly. Use the GNUNET_strndup macro.
+ *
  * @param str string to duplicate
- * @param len lenght of the string to duplicate
+ * @param len length of the string to duplicate
  * @param filename where is this call being made (for debugging)
  * @param linenumber line where this call is being made (for debugging)
  * @return the duplicated string
index 7ee3c109df83dff988b8197c98c291cc88353997..3e48d32ea3b0459606584b7c8388df3e0d9c5ca0 100644 (file)
@@ -341,12 +341,12 @@ GNUNET_CONNECTION_notify_transmit_ready (struct GNUNET_CONNECTION_Handle *sock,
  * Cancel the specified transmission-ready
  * notification.
  *
- * @param h handle for notification to cancel
+ * @param th handle for notification to cancel
  */
 void
 GNUNET_CONNECTION_notify_transmit_ready_cancel (struct
                                                 GNUNET_CONNECTION_TransmitHandle
-                                                *h);
+                                                *th);
 
 
 /**
index b9447fe096a3be91d8ff9954930a5c0d4453efe4..4729ae60d0ae4b6287de4791e4d2406ec38fe1cd 100644 (file)
@@ -56,8 +56,7 @@ struct GNUNET_MESH_Tunnel;
 
 /**
  * Functions with this signature are called whenever a message is
- * received or transmitted.
- * FIXME: transmitted???
+ * received.
  *
  * @param cls closure (set from GNUNET_MESH_connect)
  * @param tunnel connection to the other end
@@ -126,6 +125,26 @@ typedef void (GNUNET_MESH_TunnelEndHandler) (void *cls,
 typedef uint32_t GNUNET_MESH_ApplicationType;
 
 
+/**
+ * Method called whenever another peer has added us to a tunnel
+ * the other peer initiated.
+ *
+ * @param cls closure
+ * @param tunnel new handle to the tunnel
+ * @param initiator peer that started the tunnel
+ * @param atsi performance information for the tunnel
+ * @return initial tunnel context for the tunnel (can be NULL -- that's not an error)
+ */
+typedef void* (*GNUNET_MESH_InboundTunnelNotificationHandler) (void *cls,
+                                                              struct GNUNET_MESH_Tunnel * tunnel,
+                                                              const struct
+                                                              GNUNET_PeerIdentity *
+                                                              initiator,
+                                                              const struct
+                                                              GNUNET_TRANSPORT_ATS_Information *
+                                                              atsi);
+
+
 /**
  * Connect to the mesh service.
  *
@@ -194,12 +213,14 @@ typedef void (*GNUNET_MESH_TunnelConnectHandler) (void *cls,
  * and to broadcast).
  *
  * @param h mesh handle
+ * @param tunnel_ctx client's tunnel context to associate with the tunnel
  * @param connect_handler function to call when peers are actually connected
  * @param disconnect_handler function to call when peers are disconnected
  * @param handler_cls closure for connect/disconnect handlers
  */
 struct GNUNET_MESH_Tunnel *
 GNUNET_MESH_tunnel_create (struct GNUNET_MESH_Handle *h,
+                          void *tunnel_ctx,
                            GNUNET_MESH_TunnelConnectHandler connect_handler,
                            GNUNET_MESH_TunnelDisconnectHandler
                            disconnect_handler, void *handler_cls);
index e55a014e63685a7f1bc286c8bd4188e81e03a2d2..ca6544e94f70425d8c35429a410a7700ce265815 100644 (file)
@@ -64,7 +64,7 @@ struct GNUNET_RESOLVER_RequestHandle;
  * @param cfg configuration to use
  */
 void
-GNUNET_RESOLVER_connect (const struct GNUNET_CONFIGURATION_Handle *c);
+GNUNET_RESOLVER_connect (const struct GNUNET_CONFIGURATION_Handle *cfg);
 
 
 /**