diff options
Diffstat (limited to 'src/include/gnunet_network_lib.h')
-rw-r--r-- | src/include/gnunet_network_lib.h | 21 |
1 files changed, 14 insertions, 7 deletions
diff --git a/src/include/gnunet_network_lib.h b/src/include/gnunet_network_lib.h index 492713c46..d966c3afe 100644 --- a/src/include/gnunet_network_lib.h +++ b/src/include/gnunet_network_lib.h | |||
@@ -68,17 +68,18 @@ GNUNET_NETWORK_socket_accept (const struct GNUNET_NETWORK_Handle *desc, | |||
68 | * Make a non-inheritable to child processes (sets the | 68 | * Make a non-inheritable to child processes (sets the |
69 | * close-on-exec flag). | 69 | * close-on-exec flag). |
70 | * | 70 | * |
71 | * @param socket | 71 | * @param h the socket to make non-inheritable |
72 | * @return GNUNET_OK on success, GNUNET_SYSERR otherwise | 72 | * @return GNUNET_OK on success, GNUNET_SYSERR otherwise |
73 | * @warning Not implemented on Windows | 73 | * @warning Not implemented on Windows |
74 | */ | 74 | */ |
75 | int | 75 | int |
76 | GNUNET_NETWORK_socket_set_inheritable (const struct GNUNET_NETWORK_Handle | 76 | GNUNET_NETWORK_socket_set_inheritable (const struct GNUNET_NETWORK_Handle |
77 | *desc); | 77 | *h); |
78 | 78 | ||
79 | /** | 79 | /** |
80 | * Bind to a connected socket | 80 | * Bind to a connected socket |
81 | * @param desc socket | 81 | * |
82 | * @param desc socket to bind | ||
82 | * @param address address to be bound | 83 | * @param address address to be bound |
83 | * @param address_len length of address | 84 | * @param address_len length of address |
84 | * @return GNUNET_OK on success, GNUNET_SYSERR otherwise | 85 | * @return GNUNET_OK on success, GNUNET_SYSERR otherwise |
@@ -88,14 +89,16 @@ int GNUNET_NETWORK_socket_bind (struct GNUNET_NETWORK_Handle *desc, | |||
88 | 89 | ||
89 | /** | 90 | /** |
90 | * Close a socket | 91 | * Close a socket |
91 | * @param desc socket | 92 | * |
93 | * @param desc socket to close | ||
92 | * @return GNUNET_OK on success, GNUNET_SYSERR otherwise | 94 | * @return GNUNET_OK on success, GNUNET_SYSERR otherwise |
93 | */ | 95 | */ |
94 | int GNUNET_NETWORK_socket_close (struct GNUNET_NETWORK_Handle *desc); | 96 | int GNUNET_NETWORK_socket_close (struct GNUNET_NETWORK_Handle *desc); |
95 | 97 | ||
96 | /** | 98 | /** |
97 | * Connect a socket | 99 | * Connect a socket |
98 | * @param desc socket | 100 | * |
101 | * @param desc socket to connect | ||
99 | * @param address peer address | 102 | * @param address peer address |
100 | * @param length of address | 103 | * @param length of address |
101 | * @return GNUNET_OK on success, GNUNET_SYSERR otherwise | 104 | * @return GNUNET_OK on success, GNUNET_SYSERR otherwise |
@@ -103,9 +106,11 @@ int GNUNET_NETWORK_socket_close (struct GNUNET_NETWORK_Handle *desc); | |||
103 | int GNUNET_NETWORK_socket_connect (const struct GNUNET_NETWORK_Handle *desc, | 106 | int GNUNET_NETWORK_socket_connect (const struct GNUNET_NETWORK_Handle *desc, |
104 | const struct sockaddr *address, socklen_t address_len); | 107 | const struct sockaddr *address, socklen_t address_len); |
105 | 108 | ||
109 | |||
106 | /** | 110 | /** |
107 | * Get socket options | 111 | * Get socket options |
108 | * @param desc socket | 112 | * |
113 | * @param desc socket to inspect | ||
109 | * @param level protocol level of the option | 114 | * @param level protocol level of the option |
110 | * @param optname identifier of the option | 115 | * @param optname identifier of the option |
111 | * @param optval options | 116 | * @param optval options |
@@ -115,9 +120,11 @@ int GNUNET_NETWORK_socket_connect (const struct GNUNET_NETWORK_Handle *desc, | |||
115 | int GNUNET_NETWORK_socket_getsockopt(const struct GNUNET_NETWORK_Handle *desc, int level, int optname, | 120 | int GNUNET_NETWORK_socket_getsockopt(const struct GNUNET_NETWORK_Handle *desc, int level, int optname, |
116 | void *optval, socklen_t *optlen); | 121 | void *optval, socklen_t *optlen); |
117 | 122 | ||
123 | |||
118 | /** | 124 | /** |
119 | * Listen on a socket | 125 | * Listen on a socket |
120 | * @param desc socket | 126 | * |
127 | * @param desc socket to start listening on | ||
121 | * @param backlog length of the listen queue | 128 | * @param backlog length of the listen queue |
122 | * @return GNUNET_OK on success, GNUNET_SYSERR otherwise | 129 | * @return GNUNET_OK on success, GNUNET_SYSERR otherwise |
123 | */ | 130 | */ |