cleanup
authorChristian Grothoff <christian@grothoff.org>
Mon, 15 Aug 2011 12:44:36 +0000 (12:44 +0000)
committerChristian Grothoff <christian@grothoff.org>
Mon, 15 Aug 2011 12:44:36 +0000 (12:44 +0000)
src/include/gnunet_container_lib.h
src/include/gnunet_network_lib.h
src/util/container_slist.c

index 4582c1a144b60cda312bd8def87c0455435c8e94..3319b710bf6edf4c984ce5abc6bee19e0f75f807 100644 (file)
@@ -1199,7 +1199,7 @@ int GNUNET_CONTAINER_slist_end (struct GNUNET_CONTAINER_SList_Iterator *i);
  * @param len set to the payload length
  * @return payload
  */
-const void *
+void *
 GNUNET_CONTAINER_slist_get (const struct GNUNET_CONTAINER_SList_Iterator *i, 
                            size_t *len);
 
index aed4cabbf18b459f450494d66feb6ee81e94c015..1405efa2a9a9b8877295e7b59cb1f16444ac2aa9 100644 (file)
@@ -36,12 +36,12 @@ extern "C"
 #endif
 
 
-
 /**
  * @brief handle to a socket
  */
 struct GNUNET_NETWORK_Handle;
 
+
 /**
  * @brief collection of IO descriptors
  */
@@ -122,6 +122,7 @@ int GNUNET_NETWORK_socket_bind (struct GNUNET_NETWORK_Handle *desc,
  */
 int GNUNET_NETWORK_socket_close (struct GNUNET_NETWORK_Handle *desc);
 
+
 /**
  * Connect a socket
  *
@@ -160,6 +161,7 @@ int GNUNET_NETWORK_socket_getsockopt (const struct GNUNET_NETWORK_Handle
 int GNUNET_NETWORK_socket_listen (const struct GNUNET_NETWORK_Handle *desc,
                                   int backlog);
 
+
 /**
  * How much data is available to be read on this descriptor?
  * @param desc socket
@@ -168,6 +170,7 @@ ssize_t
 GNUNET_NETWORK_socket_recvfrom_amount (const struct GNUNET_NETWORK_Handle
                                        *desc);
 
+
 /**
  * Read data from a connected socket (always non-blocking).
  * @param desc socket
@@ -183,6 +186,7 @@ GNUNET_NETWORK_socket_recvfrom (const struct GNUNET_NETWORK_Handle *desc,
                                 struct sockaddr *src_addr,
                                 socklen_t * addrlen);
 
+
 /**
  * Read data from a connected socket (always non-blocking).
  *
@@ -194,6 +198,7 @@ GNUNET_NETWORK_socket_recvfrom (const struct GNUNET_NETWORK_Handle *desc,
 ssize_t GNUNET_NETWORK_socket_recv (const struct GNUNET_NETWORK_Handle *desc,
                                     void *buffer, size_t length);
 
+
 /**
  * Check if sockets meet certain conditions
  * @param rfds set of sockets to be checked for readability
@@ -208,7 +213,6 @@ int GNUNET_NETWORK_socket_select (struct GNUNET_NETWORK_FDSet *rfds,
                                   struct GNUNET_TIME_Relative timeout);
 
 
-
 /**
  * Send data (always non-blocking).
  *
@@ -238,8 +242,10 @@ ssize_t GNUNET_NETWORK_socket_sendto (const struct GNUNET_NETWORK_Handle
                                       const struct sockaddr *dest_addr,
                                       socklen_t dest_len);
 
+
 /**
  * Set socket option
+ *
  * @param fd socket
  * @param level protocol level of the option
  * @param option_name option identifier
@@ -252,8 +258,10 @@ int GNUNET_NETWORK_socket_setsockopt (struct GNUNET_NETWORK_Handle *fd,
                                       const void *option_value,
                                       socklen_t option_len);
 
+
 /**
  * Shut down socket operations
+ *
  * @param desc socket
  * @param how type of shutdown
  * @return GNUNET_OK on success, GNUNET_SYSERR otherwise
@@ -261,6 +269,7 @@ int GNUNET_NETWORK_socket_setsockopt (struct GNUNET_NETWORK_Handle *fd,
 int GNUNET_NETWORK_socket_shutdown (struct GNUNET_NETWORK_Handle *desc,
                                     int how);
 
+
 /**
  * Disable the "CORK" feature for communication with the given socket,
  * forcing the OS to immediately flush the buffer on transmission
@@ -287,6 +296,7 @@ struct GNUNET_NETWORK_Handle *GNUNET_NETWORK_socket_create (int domain,
                                                             int type,
                                                             int protocol);
 
+
 /**
  * Reset FD set (clears all file descriptors).
  *
@@ -294,6 +304,7 @@ struct GNUNET_NETWORK_Handle *GNUNET_NETWORK_socket_create (int domain,
  */
 void GNUNET_NETWORK_fdset_zero (struct GNUNET_NETWORK_FDSet *fds);
 
+
 /**
  * Add a socket to the FD set
  * @param fds fd set
@@ -325,6 +336,7 @@ GNUNET_NETWORK_fdset_handle_set_native_w32_handle (struct GNUNET_NETWORK_FDSet *
 int GNUNET_NETWORK_fdset_isset (const struct GNUNET_NETWORK_FDSet *fds,
                                 const struct GNUNET_NETWORK_Handle *desc);
 
+
 /**
  * Add one fd set to another
  * @param dst the fd set to add to
@@ -333,6 +345,7 @@ int GNUNET_NETWORK_fdset_isset (const struct GNUNET_NETWORK_FDSet *fds,
 void GNUNET_NETWORK_fdset_add (struct GNUNET_NETWORK_FDSet *dst,
                                const struct GNUNET_NETWORK_FDSet *src);
 
+
 /**
  * Copy one fd set to another
  * @param to destination
@@ -350,6 +363,7 @@ void GNUNET_NETWORK_fdset_copy (struct GNUNET_NETWORK_FDSet *to,
  */
 int GNUNET_NETWORK_get_fd (struct GNUNET_NETWORK_Handle *desc);
 
+
 /**
  * Copy a native fd set
  * @param to destination
@@ -390,6 +404,7 @@ GNUNET_NETWORK_fdset_test_native (const struct GNUNET_NETWORK_FDSet *to,
 void GNUNET_NETWORK_fdset_handle_set (struct GNUNET_NETWORK_FDSet *fds,
                                       const struct GNUNET_DISK_FileHandle *h);
 
+
 /**
  * Check if a file handle is part of an fd set
  * @param fds fd set
@@ -400,6 +415,7 @@ int GNUNET_NETWORK_fdset_handle_isset (const struct GNUNET_NETWORK_FDSet *fds,
                                        const struct GNUNET_DISK_FileHandle
                                        *h);
 
+
 /**
  * Checks if two fd sets overlap
  * @param fds1 first fd set
@@ -409,12 +425,14 @@ int GNUNET_NETWORK_fdset_handle_isset (const struct GNUNET_NETWORK_FDSet *fds,
 int GNUNET_NETWORK_fdset_overlap (const struct GNUNET_NETWORK_FDSet *fds1,
                                   const struct GNUNET_NETWORK_FDSet *fds2);
 
+
 /**
  * Creates an fd set
  * @return a new fd set
  */
 struct GNUNET_NETWORK_FDSet *GNUNET_NETWORK_fdset_create (void);
 
+
 /**
  * Releases the associated memory of an fd set
  * @param fds fd set
index 8c4886ef540106959b6ae0968f8b22f6bcccc595..cecc74ce2594ac78c00167ba15c1bf951e138d0c 100644 (file)
@@ -380,7 +380,7 @@ GNUNET_CONTAINER_slist_end (struct GNUNET_CONTAINER_SList_Iterator *i)
  * @param len payload length
  * @return payload
  */
-const void *
+void *
 GNUNET_CONTAINER_slist_get (const struct GNUNET_CONTAINER_SList_Iterator *i,
                             size_t * len)
 {