gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] r15167 - in gnunet/src: include mesh


From: gnunet
Subject: [GNUnet-SVN] r15167 - in gnunet/src: include mesh
Date: Fri, 6 May 2011 00:21:31 +0200

Author: bartpolot
Date: 2011-05-06 00:21:31 +0200 (Fri, 06 May 2011)
New Revision: 15167

Modified:
   gnunet/src/include/gnunet_mesh_service.h
   gnunet/src/mesh/mesh.h
   gnunet/src/mesh/mesh_api_new.c
Log:
WiP


Modified: gnunet/src/include/gnunet_mesh_service.h
===================================================================
--- gnunet/src/include/gnunet_mesh_service.h    2011-05-05 19:03:44 UTC (rev 
15166)
+++ gnunet/src/include/gnunet_mesh_service.h    2011-05-05 22:21:31 UTC (rev 
15167)
@@ -131,6 +131,7 @@
  *                note that the mesh is allowed to drop notifications about 
inbound
  *                messages if the client does not process them fast enough 
(for this
  *                notification type, a bounded queue is used)
+ * @param stypes Application Types the client claims to offer
  * @return handle to the mesh service 
  *           NULL on error (in this case, init is never called)
  */

Modified: gnunet/src/mesh/mesh.h
===================================================================
--- gnunet/src/mesh/mesh.h      2011-05-05 19:03:44 UTC (rev 15166)
+++ gnunet/src/mesh/mesh.h      2011-05-05 22:21:31 UTC (rev 15167)
@@ -39,7 +39,7 @@
  * 
  * API CALL (GNUNET_MESH_*)             MESSAGE USED
  * ------------------------             ------------
- * connect                              None (Header + [types])
+ * connect                              GNUNET_MESH_ClientConnect
  * disconnect                           None (network level disconnect)
  *
  * tunnel_create                        GNUNET_MESH_TunnelMessage
@@ -65,6 +65,23 @@
  */
 
 /**
+ * Message for a client to register to the service
+ */
+struct GNUNET_MESH_ClientConnect {
+    /**
+     * Type: GNUNET_MESSAGE_TYPE_MESH_LOCAL_CONNECT
+     *
+     * Size: sizeof(struct GNUNET_MESH_ClientConnect) +
+     *       sizeof(uint16_t) * types +
+     *       sizeof(MESH_ApplicationType) * applications
+     */
+    struct GNUNET_MessageHeader header;
+    uint16_t                    types;
+    uint16_t                    applications;
+};
+
+
+/**
  * Type for tunnel numbering.
  * - Local tunnel numbers are >= 0x80000000
  * - Global tunnel numbers are < 0x80000000

Modified: gnunet/src/mesh/mesh_api_new.c
===================================================================
--- gnunet/src/mesh/mesh_api_new.c      2011-05-05 19:03:44 UTC (rev 15166)
+++ gnunet/src/mesh/mesh_api_new.c      2011-05-05 22:21:31 UTC (rev 15167)
@@ -72,6 +72,7 @@
  *                 note that the mesh is allowed to drop notifications about
  *                 inbound messages if the client does not process them fast
  *                 enough (for this notification type, a bounded queue is used)
+ * @param stypes Application Types the client claims to offer
  * @return handle to the mesh service 
  *         NULL on error (in this case, init is never called)
  */
@@ -79,7 +80,7 @@
 GNUNET_MESH_connect (const struct GNUNET_CONFIGURATION_Handle *cfg,
                      void *cls,
                      GNUNET_MESH_TunnelEndHandler cleaner,
-                     const struct GNUNET_MESH_MessageHandler *handlers, 
+                     const struct GNUNET_MESH_MessageHandler *handlers,
                      const GNUNET_MESH_ApplicationType *stypes) {
     GNUNET_MESH_Handle                  *h;
     struct GNUNET_MESH_MessageHandler   *aux;




reply via email to

[Prev in Thread] Current Thread [Next in Thread]