fixing remaining network-connection naming confusion in API
authorChristian Grothoff <christian@grothoff.org>
Sat, 29 Aug 2009 18:34:03 +0000 (18:34 +0000)
committerChristian Grothoff <christian@grothoff.org>
Sat, 29 Aug 2009 18:34:03 +0000 (18:34 +0000)
15 files changed:
src/core/core_api.c
src/core/gnunet-service-core.c
src/include/gnunet_client_lib.h
src/include/gnunet_connection_lib.h
src/include/gnunet_core_service.h
src/include/gnunet_server_lib.h
src/include/gnunet_transport_service.h
src/transport/gnunet-service-transport.c
src/transport/plugin_transport_tcp.c
src/transport/transport_api.c
src/util/client.c
src/util/network.c
src/util/server.c
src/util/test_network_transmit_cancel.c
src/util/test_server.c

index 619a0420f00de94688530a3ae8313a82957664a7..ac958449be8ea570bac70b6ce9b39054103ffbca 100644 (file)
@@ -94,7 +94,7 @@ struct GNUNET_CORE_Handle
   /**
    * Handle for our current transmission request.
    */
-  struct GNUNET_NETWORK_TransmitHandle *th;
+  struct GNUNET_CONNECTION_TransmitHandle *th;
 
   /**
    * Head of doubly-linked list of pending requests.
@@ -173,7 +173,7 @@ struct GNUNET_CORE_TransmitHandle
    * The function will be called with a NULL buffer to signal
    * timeout.
    */
-  GNUNET_NETWORK_TransmitReadyNotify get_message;
+  GNUNET_CONNECTION_TransmitReadyNotify get_message;
 
   /**
    * Closure for get_message.
@@ -195,7 +195,7 @@ struct GNUNET_CORE_TransmitHandle
    * If this entry is for a transmission request, pointer
    * to the notify callback; otherwise NULL.
    */
-  GNUNET_NETWORK_TransmitReadyNotify notify;
+  GNUNET_CONNECTION_TransmitReadyNotify notify;
 
   /**
    * Closure for notify.
@@ -961,7 +961,7 @@ produce_send (void *cls, size_t size, void *buf)
   struct GNUNET_CORE_Handle *h;
   struct SendMessage *sm;
   size_t dt;
-  GNUNET_NETWORK_TransmitReadyNotify notify;
+  GNUNET_CONNECTION_TransmitReadyNotify notify;
   void *notify_cls;
 
   h = th->ch;
@@ -1026,7 +1026,7 @@ GNUNET_CORE_notify_transmit_ready (struct GNUNET_CORE_Handle *handle,
                                    struct GNUNET_TIME_Relative maxdelay,
                                    const struct GNUNET_PeerIdentity *target,
                                    size_t notify_size,
-                                   GNUNET_NETWORK_TransmitReadyNotify notify,
+                                   GNUNET_CONNECTION_TransmitReadyNotify notify,
                                    void *notify_cls)
 {
   struct GNUNET_CORE_TransmitHandle *th;
index eab031f1c39f5f46c51c8b79167ebeca9a35b196..ec2f08f657e73e71ac90e0b54390ad8e4ca2df6a 100644 (file)
@@ -570,7 +570,7 @@ struct Client
    * Current transmit handle, NULL if no transmission request
    * is pending.
    */
-  struct GNUNET_NETWORK_TransmitHandle *th;
+  struct GNUNET_CONNECTION_TransmitHandle *th;
 
   /**
    * Array of the types of messages this peer cares
index 4ac993deac5404c1f5b2db662f764e8f53b4786e..8651b273c678a877d16326d93262dfc28f01c422 100644 (file)
@@ -111,11 +111,11 @@ void GNUNET_CLIENT_receive (struct GNUNET_CLIENT_Connection *sock,
  *         non-NULL if the notify callback was queued (can be used to cancel
  *         using GNUNET_CONNECTION_notify_transmit_ready_cancel)
  */
-struct GNUNET_NETWORK_TransmitHandle
+struct GNUNET_CONNECTION_TransmitHandle
   *GNUNET_CLIENT_notify_transmit_ready (struct GNUNET_CLIENT_Connection *sock,
                                         size_t size,
                                         struct GNUNET_TIME_Relative timeout,
-                                        GNUNET_NETWORK_TransmitReadyNotify
+                                        GNUNET_CONNECTION_TransmitReadyNotify
                                         notify, void *notify_cls);
 
 
index 41d56ec0f38f861709ffbe5a067d74475f920378..9a0d1cfbe8e2e38635c1e6bb46dae232d99c3571 100644 (file)
@@ -42,7 +42,7 @@ extern "C"
  * Timeout we use on TCP connect before trying another\r
  * result from the DNS resolver. 5s.\r
  */\r
-#define GNUNET_NETWORK_CONNECT_RETRY_TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 5)\r
+#define GNUNET_CONNECTION_CONNECT_RETRY_TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 5)\r
 \r
 /**\r
  * @brief handle for a network connection\r
@@ -59,7 +59,7 @@ struct GNUNET_CONNECTION_Handle;
  * @return GNUNET_YES to allow, GNUNET_NO to deny, GNUNET_SYSERR\r
  *   for unknown address family (will be denied).\r
  */\r
-typedef int (*GNUNET_NETWORK_AccessCheck) (void *cls,\r
+typedef int (*GNUNET_CONNECTION_AccessCheck) (void *cls,\r
                                            const struct sockaddr * addr,\r
                                            socklen_t addrlen);\r
 \r
@@ -76,7 +76,7 @@ typedef int (*GNUNET_NETWORK_AccessCheck) (void *cls,
  * @param addrlen size of addr\r
  * @param errCode value of errno (on errors receiving)\r
  */\r
-typedef void (*GNUNET_NETWORK_Receiver) (void *cls,\r
+typedef void (*GNUNET_CONNECTION_Receiver) (void *cls,\r
                                          const void *buf,\r
                                          size_t available,\r
                                          const struct sockaddr * addr,\r
@@ -119,7 +119,7 @@ struct GNUNET_CONNECTION_Handle
   *GNUNET_CONNECTION_create_from_accept (struct\r
                                                  GNUNET_SCHEDULER_Handle\r
                                                  *sched,\r
-                                                 GNUNET_NETWORK_AccessCheck\r
+                                                 GNUNET_CONNECTION_AccessCheck\r
                                                  access, void *access_cls,\r
                                                  struct\r
                                                  GNUNET_NETWORK_Descriptor\r
@@ -224,7 +224,7 @@ GNUNET_SCHEDULER_TaskIdentifier
 GNUNET_CONNECTION_receive (struct GNUNET_CONNECTION_Handle\r
                                    *sock, size_t max,\r
                                    struct GNUNET_TIME_Relative timeout,\r
-                                   GNUNET_NETWORK_Receiver receiver,\r
+                                   GNUNET_CONNECTION_Receiver receiver,\r
                                    void *receiver_cls);\r
 \r
 \r
@@ -255,7 +255,7 @@ void *GNUNET_CONNECTION_receive_cancel (struct
  * @param buf where the callee should write the message\r
  * @return number of bytes written to buf\r
  */\r
-typedef size_t (*GNUNET_NETWORK_TransmitReadyNotify) (void *cls,\r
+typedef size_t (*GNUNET_CONNECTION_TransmitReadyNotify) (void *cls,\r
                                                       size_t size, void *buf);\r
 \r
 \r
@@ -263,7 +263,7 @@ typedef size_t (*GNUNET_NETWORK_TransmitReadyNotify) (void *cls,
  * Opaque handle that can be used to cancel\r
  * a transmit-ready notification.\r
  */\r
-struct GNUNET_NETWORK_TransmitHandle;\r
+struct GNUNET_CONNECTION_TransmitHandle;\r
 \r
 /**\r
  * Ask the socket to call us once the specified number of bytes\r
@@ -294,14 +294,14 @@ struct GNUNET_NETWORK_TransmitHandle;
  * @return non-NULL if the notify callback was queued,\r
  *         NULL if we are already going to notify someone else (busy)\r
  */\r
-struct GNUNET_NETWORK_TransmitHandle\r
+struct GNUNET_CONNECTION_TransmitHandle\r
   *GNUNET_CONNECTION_notify_transmit_ready (struct\r
                                                     GNUNET_CONNECTION_Handle\r
                                                     *sock, size_t size,\r
                                                     struct\r
                                                     GNUNET_TIME_Relative\r
                                                     timeout,\r
-                                                    GNUNET_NETWORK_TransmitReadyNotify\r
+                                                    GNUNET_CONNECTION_TransmitReadyNotify\r
                                                     notify, void *notify_cls);\r
 \r
 \r
@@ -313,7 +313,7 @@ struct GNUNET_NETWORK_TransmitHandle
  */\r
 void\r
 GNUNET_CONNECTION_notify_transmit_ready_cancel (struct\r
-                                                        GNUNET_NETWORK_TransmitHandle\r
+                                                        GNUNET_CONNECTION_TransmitHandle\r
                                                         *h);\r
 \r
 \r
index b2a19986d647c3caaa00191e2cdb1ca83214b441..5d08552f4942e8e3a5edb3dc0ea3dea3d315bd12 100644 (file)
@@ -289,7 +289,7 @@ GNUNET_CORE_notify_transmit_ready (struct
                                   *target,
                                   size_t
                                   notify_size,
-                                  GNUNET_NETWORK_TransmitReadyNotify
+                                  GNUNET_CONNECTION_TransmitReadyNotify
                                   notify,
                                   void
                                   *notify_cls);
index bed5786abf3a386e2d64f492720430e11c35085c..632833035db7688dcaaa4af6da203e77508ba3bc 100644 (file)
@@ -127,7 +127,7 @@ struct GNUNET_SERVER_MessageHandler
 struct GNUNET_SERVER_Handle *GNUNET_SERVER_create (struct
                                                    GNUNET_SCHEDULER_Handle
                                                    *sched,
-                                                   GNUNET_NETWORK_AccessCheck
+                                                   GNUNET_CONNECTION_AccessCheck
                                                    access, void *access_cls,
                                                    const struct sockaddr
                                                    *serverAddr,
@@ -178,11 +178,11 @@ GNUNET_SERVER_add_handlers (struct GNUNET_SERVER_Handle *server,
  *           GNUNET_CONNECTION_notify_transmit_ready_cancel.
  *         NULL if we are already going to notify someone else (busy)
  */
-struct GNUNET_NETWORK_TransmitHandle
+struct GNUNET_CONNECTION_TransmitHandle
   *GNUNET_SERVER_notify_transmit_ready (struct GNUNET_SERVER_Client *client,
                                         size_t size,
                                         struct GNUNET_TIME_Relative timeout,
-                                        GNUNET_NETWORK_TransmitReadyNotify
+                                        GNUNET_CONNECTION_TransmitReadyNotify
                                         callback, void *callback_cls);
 
 
@@ -261,7 +261,7 @@ typedef GNUNET_SCHEDULER_TaskIdentifier
   (*GNUNET_SERVER_ReceiveCallback) (void *cls,
                                     size_t max,
                                     struct GNUNET_TIME_Relative timeout,
-                                    GNUNET_NETWORK_Receiver
+                                    GNUNET_CONNECTION_Receiver
                                     receiver, void *receiver_cls);
 
 
@@ -294,7 +294,7 @@ typedef void *(*GNUNET_SERVER_TransmitReadyCallback) (void *cls,
                                                       struct
                                                       GNUNET_TIME_Relative
                                                       timeout,
-                                                      GNUNET_NETWORK_TransmitReadyNotify
+                                                      GNUNET_CONNECTION_TransmitReadyNotify
                                                       notify,
                                                       void *notify_cls);
 
index 385bf7cfb84b42858e6878907c1b6d6d3cf509ec..604610774a4e23edf6e30003637aa0ebec84261a 100644 (file)
@@ -186,7 +186,7 @@ struct GNUNET_TRANSPORT_TransmitHandle
                                           unsigned int priority,
                                            struct GNUNET_TIME_Relative
                                            timeout,
-                                           GNUNET_NETWORK_TransmitReadyNotify
+                                           GNUNET_CONNECTION_TransmitReadyNotify
                                            notify, void *notify_cls);
 
 
index 2b1e82d21f9bf910bc30e93a595b1168234f7b80..3e696827f20c247338acfec2288fee427a8d35ca 100644 (file)
@@ -667,7 +667,7 @@ transmit_to_client_callback (void *cls, size_t size, void *buf)
   uint16_t msize;
   size_t tsize;
   const struct GNUNET_MessageHeader *msg;
-  struct GNUNET_NETWORK_TransmitHandle *th;
+  struct GNUNET_CONNECTION_TransmitHandle *th;
   char *cbuf;
 
   if (buf == NULL)
@@ -730,7 +730,7 @@ transmit_to_client (struct TransportClient *client,
 {
   struct ClientMessageQueueEntry *q;
   uint16_t msize;
-  struct GNUNET_NETWORK_TransmitHandle *th;
+  struct GNUNET_CONNECTION_TransmitHandle *th;
 
   if ((client->message_count >= MAX_PENDING) && (GNUNET_YES == may_drop))
     {
index c14654be09186588710a4c73be725523a12a2523..17570254bd974b10cd2f94a86e11cf82363a1464 100644 (file)
@@ -277,7 +277,7 @@ struct Session
   /**
    * Handle for pending transmission request.
    */
-  struct GNUNET_NETWORK_TransmitHandle *transmit_handle;
+  struct GNUNET_CONNECTION_TransmitHandle *transmit_handle;
 
   /**
    * To whom are we talking to (set to our identity
index 451b66c1285c224763eed7808ee00d69f15dc522..aa1a3f9a12c3f1ba535f3f2c09bef7bfd2a75e94 100644 (file)
@@ -203,7 +203,7 @@ struct GNUNET_TRANSPORT_TransmitHandle
    * Function to call when notify_size bytes are available
    * for transmission.
    */
-  GNUNET_NETWORK_TransmitReadyNotify notify;
+  GNUNET_CONNECTION_TransmitReadyNotify notify;
 
   /**
    * Closure for notify.
@@ -278,7 +278,7 @@ struct GNUNET_TRANSPORT_Handle
   /**
    * Handle to our registration with the client for notification.
    */
-  struct GNUNET_NETWORK_TransmitHandle *network_handle;
+  struct GNUNET_CONNECTION_TransmitHandle *network_handle;
 
   /**
    * Linked list of transmit handles that are waiting for the
@@ -605,7 +605,7 @@ schedule_control_transmit (struct GNUNET_TRANSPORT_Handle *h,
                            size_t size,
                            int at_head,
                            struct GNUNET_TIME_Relative timeout,
-                           GNUNET_NETWORK_TransmitReadyNotify notify,
+                           GNUNET_CONNECTION_TransmitReadyNotify notify,
                            void *notify_cls)
 {
   struct GNUNET_TRANSPORT_TransmitHandle *th;
@@ -1768,7 +1768,7 @@ demultiplexer (void *cls, const struct GNUNET_MessageHeader *msg)
 
 struct ClientTransmitWrapper
 {
-  GNUNET_NETWORK_TransmitReadyNotify notify;
+  GNUNET_CONNECTION_TransmitReadyNotify notify;
   void *notify_cls;
   struct GNUNET_TRANSPORT_TransmitHandle *th;
 };
@@ -1856,7 +1856,7 @@ GNUNET_TRANSPORT_notify_transmit_ready (struct GNUNET_TRANSPORT_Handle
                                         *target, size_t size,
                                        unsigned int priority,
                                         struct GNUNET_TIME_Relative timeout,
-                                        GNUNET_NETWORK_TransmitReadyNotify
+                                        GNUNET_CONNECTION_TransmitReadyNotify
                                         notify, void *notify_cls)
 {
   struct GNUNET_TRANSPORT_TransmitHandle *pos;
index 09eaeff1af46ba0fd50d67054a98a49379d47190..0c639c905fb86b0d32d39011a10d6cf33fcb9248 100644 (file)
@@ -508,11 +508,11 @@ GNUNET_CLIENT_service_test (struct GNUNET_SCHEDULER_Handle *sched,
  * @return NULL if our buffer will never hold size bytes,
  *         a handle if the notify callback was queued (can be used to cancel)
  */
-struct GNUNET_NETWORK_TransmitHandle *
+struct GNUNET_CONNECTION_TransmitHandle *
 GNUNET_CLIENT_notify_transmit_ready (struct GNUNET_CLIENT_Connection *sock,
                                      size_t size,
                                      struct GNUNET_TIME_Relative timeout,
-                                     GNUNET_NETWORK_TransmitReadyNotify
+                                     GNUNET_CONNECTION_TransmitReadyNotify
                                      notify, void *notify_cls)
 {
   return GNUNET_CONNECTION_notify_transmit_ready (sock->sock,
index fd5fe1217aef14d517dbf88fa38d4a7b5f5dfd2c..35dfc69cae97a7b63acf0389504bae52642e2f0f 100644 (file)
 static int address_families[] = 
   { AF_INET, AF_INET6, AF_UNSPEC };
 
-struct GNUNET_NETWORK_TransmitHandle
+struct GNUNET_CONNECTION_TransmitHandle
 {
 
   /**
    * Function to call if the send buffer has notify_size
    * bytes available.
    */
-  GNUNET_NETWORK_TransmitReadyNotify notify_ready;
+  GNUNET_CONNECTION_TransmitReadyNotify notify_ready;
 
   /**
    * Closure for notify_ready.
@@ -169,7 +169,7 @@ struct GNUNET_CONNECTION_Handle
   /**
    * The handle we return for GNUNET_CONNECTION_notify_transmit_ready.
    */
-  struct GNUNET_NETWORK_TransmitHandle nth;
+  struct GNUNET_CONNECTION_TransmitHandle nth;
 
   /**
    * Underlying OS's socket, set to NULL after fatal errors.
@@ -185,7 +185,7 @@ struct GNUNET_CONNECTION_Handle
    * Function to call on data received, NULL
    * if no receive is pending.
    */
-  GNUNET_NETWORK_Receiver receiver;
+  GNUNET_CONNECTION_Receiver receiver;
 
   /**
    * Closure for receiver.
@@ -247,7 +247,7 @@ GNUNET_CONNECTION_create_from_existing (struct GNUNET_SCHEDULER_Handle
 struct GNUNET_CONNECTION_Handle *
 GNUNET_CONNECTION_create_from_accept (struct GNUNET_SCHEDULER_Handle
                                           *sched,
-                                          GNUNET_NETWORK_AccessCheck access,
+                                          GNUNET_CONNECTION_AccessCheck access,
                                           void *access_cls, struct GNUNET_NETWORK_Descriptor *lsock,
                                           size_t maxbuf)
 {
@@ -515,7 +515,7 @@ connect_continuation (void *cls,
       sock->connect_task = GNUNET_SCHEDULER_add_write_net (tc->sched, GNUNET_NO,    /* abort on shutdown */
                                                        GNUNET_SCHEDULER_PRIORITY_KEEP,
                                                        GNUNET_SCHEDULER_NO_TASK,
-                                                       GNUNET_NETWORK_CONNECT_RETRY_TIMEOUT,
+                                                       GNUNET_CONNECTION_CONNECT_RETRY_TIMEOUT,
                                                        sock->sock,
                                                        &connect_continuation,
                                                        sock);
@@ -571,7 +571,7 @@ GNUNET_CONNECTION_create_from_connect (struct GNUNET_SCHEDULER_Handle
   ret->connect_task = GNUNET_SCHEDULER_add_write_net (sched, GNUNET_NO,     /* abort on shutdown */
                                                   GNUNET_SCHEDULER_PRIORITY_KEEP,
                                                   GNUNET_SCHEDULER_NO_TASK,
-                                                  GNUNET_NETWORK_CONNECT_RETRY_TIMEOUT,
+                                                  GNUNET_CONNECTION_CONNECT_RETRY_TIMEOUT,
                                                   ret->sock,
                                                   &connect_continuation, ret);
   return ret;
@@ -668,7 +668,7 @@ destroy_continuation (void *cls,
                       const struct GNUNET_SCHEDULER_TaskContext *tc)
 {
   struct GNUNET_CONNECTION_Handle *sock = cls;
-  GNUNET_NETWORK_TransmitReadyNotify notify;
+  GNUNET_CONNECTION_TransmitReadyNotify notify;
 
   if (sock->write_task != GNUNET_SCHEDULER_NO_TASK)
     {
@@ -742,7 +742,7 @@ GNUNET_CONNECTION_destroy (struct GNUNET_CONNECTION_Handle *sock)
 static void
 signal_timeout (struct GNUNET_CONNECTION_Handle *sh)
 {
-  GNUNET_NETWORK_Receiver receiver;
+  GNUNET_CONNECTION_Receiver receiver;
 
 #if DEBUG_NETWORK
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
@@ -760,7 +760,7 @@ signal_timeout (struct GNUNET_CONNECTION_Handle *sh)
 static void
 signal_error (struct GNUNET_CONNECTION_Handle *sh, int errcode)
 {
-  GNUNET_NETWORK_Receiver receiver;
+  GNUNET_CONNECTION_Receiver receiver;
   GNUNET_assert (NULL != (receiver = sh->receiver));
   sh->receiver = NULL;
   receiver (sh->receiver_cls, NULL, 0, sh->addr, sh->addrlen, errcode);
@@ -778,7 +778,7 @@ receive_ready (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc)
   struct GNUNET_TIME_Absolute now;
   char buffer[sh->max];
   ssize_t ret;
-  GNUNET_NETWORK_Receiver receiver;
+  GNUNET_CONNECTION_Receiver receiver;
 
   sh->read_task = GNUNET_SCHEDULER_NO_TASK;
   now = GNUNET_TIME_absolute_get ();
@@ -914,7 +914,7 @@ GNUNET_SCHEDULER_TaskIdentifier
 GNUNET_CONNECTION_receive (struct GNUNET_CONNECTION_Handle *sock,
                         size_t max,
                         struct GNUNET_TIME_Relative timeout,
-                        GNUNET_NETWORK_Receiver receiver, void *receiver_cls)
+                        GNUNET_CONNECTION_Receiver receiver, void *receiver_cls)
 {
   struct GNUNET_SCHEDULER_TaskContext tc;
 
@@ -966,7 +966,7 @@ process_notify (struct GNUNET_CONNECTION_Handle *sock)
   size_t used;
   size_t avail;
   size_t size;
-  GNUNET_NETWORK_TransmitReadyNotify notify;
+  GNUNET_CONNECTION_TransmitReadyNotify notify;
 
   GNUNET_assert (sock->write_task == GNUNET_SCHEDULER_NO_TASK);
   if (NULL == (notify = sock->nth.notify_ready))
@@ -1011,7 +1011,7 @@ static void
 transmit_timeout (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc)
 {
   struct GNUNET_CONNECTION_Handle *sock = cls;
-  GNUNET_NETWORK_TransmitReadyNotify notify;
+  GNUNET_CONNECTION_TransmitReadyNotify notify;
 
 #if DEBUG_NETWORK
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Transmit fails, time out reached.\n");
@@ -1163,11 +1163,11 @@ SCHEDULE_WRITE:
  * @return non-NULL if the notify callback was queued,
  *         NULL if we are already going to notify someone else (busy)
  */
-struct GNUNET_NETWORK_TransmitHandle *
+struct GNUNET_CONNECTION_TransmitHandle *
 GNUNET_CONNECTION_notify_transmit_ready (struct GNUNET_CONNECTION_Handle
                                       *sock, size_t size,
                                       struct GNUNET_TIME_Relative timeout,
-                                      GNUNET_NETWORK_TransmitReadyNotify
+                                      GNUNET_CONNECTION_TransmitReadyNotify
                                       notify, void *notify_cls)
 {
   if (sock->nth.notify_ready != NULL)
@@ -1229,7 +1229,7 @@ GNUNET_CONNECTION_notify_transmit_ready (struct GNUNET_CONNECTION_Handle
  */
 void
 GNUNET_CONNECTION_notify_transmit_ready_cancel (struct
-                                             GNUNET_NETWORK_TransmitHandle *h)
+                                             GNUNET_CONNECTION_TransmitHandle *h)
 {
   GNUNET_assert (h->notify_ready != NULL);
   GNUNET_SCHEDULER_cancel (h->sh->sched, h->timeout_task);
index ab52b396fcae4e95a8413b226b112043d4e0f58c..8fcc20830cc2a7588d867e2c18233d63fe78245f 100644 (file)
@@ -104,7 +104,7 @@ struct GNUNET_SERVER_Handle
   /**
    * Function to call for access control.
    */
-  GNUNET_NETWORK_AccessCheck access;
+  GNUNET_CONNECTION_AccessCheck access;
 
   /**
    * Closure for access.
@@ -443,7 +443,7 @@ open_listen_socket (const struct sockaddr *serverAddr, socklen_t socklen)
  */
 struct GNUNET_SERVER_Handle *
 GNUNET_SERVER_create (struct GNUNET_SCHEDULER_Handle *sched,
-                      GNUNET_NETWORK_AccessCheck access,
+                      GNUNET_CONNECTION_AccessCheck access,
                       void *access_cls,
                       const struct sockaddr *serverAddr,
                       socklen_t socklen,
@@ -868,7 +868,7 @@ static GNUNET_SCHEDULER_TaskIdentifier
 sock_receive (void *cls,
               size_t max,
               struct GNUNET_TIME_Relative timeout,
-              GNUNET_NETWORK_Receiver receiver, void *receiver_cls)
+              GNUNET_CONNECTION_Receiver receiver, void *receiver_cls)
 {
   return GNUNET_CONNECTION_receive (cls, max, timeout, receiver, receiver_cls);
 }
@@ -894,7 +894,7 @@ static void *
 sock_notify_transmit_ready (void *cls,
                             size_t size,
                             struct GNUNET_TIME_Relative timeout,
-                            GNUNET_NETWORK_TransmitReadyNotify notify,
+                            GNUNET_CONNECTION_TransmitReadyNotify notify,
                             void *notify_cls)
 {
   return GNUNET_CONNECTION_notify_transmit_ready (cls, size, timeout, notify,
@@ -1133,11 +1133,11 @@ GNUNET_SERVER_client_disconnect (struct GNUNET_SERVER_Client *client)
  *           GNUNET_CONNECTION_notify_transmit_ready_cancel.
  *         NULL if we are already going to notify someone else (busy)
  */
-struct GNUNET_NETWORK_TransmitHandle *
+struct GNUNET_CONNECTION_TransmitHandle *
 GNUNET_SERVER_notify_transmit_ready (struct GNUNET_SERVER_Client *client,
                                      size_t size,
                                      struct GNUNET_TIME_Relative timeout,
-                                     GNUNET_NETWORK_TransmitReadyNotify
+                                     GNUNET_CONNECTION_TransmitReadyNotify
                                      callback, void *callback_cls)
 {
   return client->notify_transmit_ready (client->client_closure,
index 351a7d444c8cc27e296792e82ee0c9fa14f8ebf9..362f29a59143643efae496584b9d6662c235f84f 100644 (file)
@@ -45,7 +45,7 @@ task_transmit_cancel (void *cls,
                       const struct GNUNET_SCHEDULER_TaskContext *tc)
 {
   int *ok = cls;
-  struct GNUNET_NETWORK_TransmitHandle *th;
+  struct GNUNET_CONNECTION_TransmitHandle *th;
   struct GNUNET_CONNECTION_Handle *csock;
 
   csock = GNUNET_CONNECTION_create_from_connect (tc->sched,
index 0f2ea3ce79b34c9a2a72cfd170149050d6229d83..20f0beffb45c09d9babe4483ed4ebcbf1627ed3d 100644 (file)
@@ -51,7 +51,7 @@ recv_fin_cb (void *cls,
 
 struct SignalTimeoutContext
 {
-  GNUNET_NETWORK_Receiver cb;
+  GNUNET_CONNECTION_Receiver cb;
   void *cb_cls;
 };
 
@@ -70,7 +70,7 @@ static GNUNET_SCHEDULER_TaskIdentifier
 my_receive (void *cls,
             size_t max,
             struct GNUNET_TIME_Relative timeout,
-            GNUNET_NETWORK_Receiver receiver, void *receiver_cls)
+            GNUNET_CONNECTION_Receiver receiver, void *receiver_cls)
 {
   int *ok = cls;
   struct GNUNET_MessageHeader msg;
@@ -118,7 +118,7 @@ static void *
 my_transmit_ready_cb (void *cls,
                       size_t size,
                       struct GNUNET_TIME_Relative timeout,
-                      GNUNET_NETWORK_TransmitReadyNotify notify,
+                      GNUNET_CONNECTION_TransmitReadyNotify notify,
                       void *notify_cls)
 {
   static int non_null_addr;