aboutsummaryrefslogtreecommitdiff
path: root/src/include/gnunet_network_lib.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/include/gnunet_network_lib.h')
-rw-r--r--src/include/gnunet_network_lib.h188
1 files changed, 92 insertions, 96 deletions
diff --git a/src/include/gnunet_network_lib.h b/src/include/gnunet_network_lib.h
index 6c02f3577..2a91621a3 100644
--- a/src/include/gnunet_network_lib.h
+++ b/src/include/gnunet_network_lib.h
@@ -11,12 +11,12 @@
11 WITHOUT ANY WARRANTY; without even the implied warranty of 11 WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Affero General Public License for more details. 13 Affero General Public License for more details.
14 14
15 You should have received a copy of the GNU Affero General Public License 15 You should have received a copy of the GNU Affero General Public License
16 along with this program. If not, see <http://www.gnu.org/licenses/>. 16 along with this program. If not, see <http://www.gnu.org/licenses/>.
17 17
18 SPDX-License-Identifier: AGPL3.0-or-later 18 SPDX-License-Identifier: AGPL3.0-or-later
19*/ 19 */
20 20
21/** 21/**
22 * @author Nils Durner 22 * @author Nils Durner
@@ -49,9 +49,7 @@ struct GNUNET_NETWORK_Handle;
49/** 49/**
50 * @brief collection of IO descriptors 50 * @brief collection of IO descriptors
51 */ 51 */
52struct GNUNET_NETWORK_FDSet 52struct GNUNET_NETWORK_FDSet {
53{
54
55 /** 53 /**
56 * Maximum number of any socket descriptor in the set (plus one) 54 * Maximum number of any socket descriptor in the set (plus one)
57 */ 55 */
@@ -80,9 +78,7 @@ struct GNUNET_NETWORK_FDSet
80 * smaller than @e handles_size. 78 * smaller than @e handles_size.
81 */ 79 */
82 unsigned int handles_pos; 80 unsigned int handles_pos;
83
84#endif 81#endif
85
86}; 82};
87 83
88#include "gnunet_disk_lib.h" 84#include "gnunet_disk_lib.h"
@@ -95,7 +91,7 @@ struct GNUNET_NETWORK_FDSet
95 * @return #GNUNET_OK if the PF is supported 91 * @return #GNUNET_OK if the PF is supported
96 */ 92 */
97int 93int
98GNUNET_NETWORK_test_pf (int pf); 94GNUNET_NETWORK_test_pf(int pf);
99 95
100 96
101/** 97/**
@@ -108,7 +104,7 @@ GNUNET_NETWORK_test_pf (int pf);
108 * @return shortened unixpath, NULL on error 104 * @return shortened unixpath, NULL on error
109 */ 105 */
110char * 106char *
111GNUNET_NETWORK_shorten_unixpath (char *unixpath); 107GNUNET_NETWORK_shorten_unixpath(char *unixpath);
112 108
113 109
114#ifndef WINDOWS 110#ifndef WINDOWS
@@ -122,7 +118,7 @@ GNUNET_NETWORK_shorten_unixpath (char *unixpath);
122 * @param un unix domain socket address to check 118 * @param un unix domain socket address to check
123 */ 119 */
124void 120void
125GNUNET_NETWORK_unix_precheck (const struct sockaddr_un *un); 121GNUNET_NETWORK_unix_precheck(const struct sockaddr_un *un);
126#endif 122#endif
127 123
128 124
@@ -137,9 +133,9 @@ GNUNET_NETWORK_unix_precheck (const struct sockaddr_un *un);
137 * @return client socket 133 * @return client socket
138 */ 134 */
139struct GNUNET_NETWORK_Handle * 135struct GNUNET_NETWORK_Handle *
140GNUNET_NETWORK_socket_accept (const struct GNUNET_NETWORK_Handle *desc, 136GNUNET_NETWORK_socket_accept(const struct GNUNET_NETWORK_Handle *desc,
141 struct sockaddr *address, 137 struct sockaddr *address,
142 socklen_t *address_len); 138 socklen_t *address_len);
143 139
144 140
145/** 141/**
@@ -149,7 +145,7 @@ GNUNET_NETWORK_socket_accept (const struct GNUNET_NETWORK_Handle *desc,
149 * @return NULL on error (including not supported on target platform) 145 * @return NULL on error (including not supported on target platform)
150 */ 146 */
151struct GNUNET_NETWORK_Handle * 147struct GNUNET_NETWORK_Handle *
152GNUNET_NETWORK_socket_box_native (SOCKTYPE fd); 148GNUNET_NETWORK_socket_box_native(SOCKTYPE fd);
153 149
154 150
155/** 151/**
@@ -160,8 +156,8 @@ GNUNET_NETWORK_socket_box_native (SOCKTYPE fd);
160 * @return #GNUNET_OK on success, #GNUNET_SYSERR on error 156 * @return #GNUNET_OK on success, #GNUNET_SYSERR on error
161 */ 157 */
162int 158int
163GNUNET_NETWORK_socket_set_blocking (struct GNUNET_NETWORK_Handle *fd, 159GNUNET_NETWORK_socket_set_blocking(struct GNUNET_NETWORK_Handle *fd,
164 int doBlock); 160 int doBlock);
165 161
166 162
167/** 163/**
@@ -173,9 +169,9 @@ GNUNET_NETWORK_socket_set_blocking (struct GNUNET_NETWORK_Handle *fd,
173 * @return #GNUNET_OK on success, #GNUNET_SYSERR otherwise 169 * @return #GNUNET_OK on success, #GNUNET_SYSERR otherwise
174 */ 170 */
175int 171int
176GNUNET_NETWORK_socket_bind (struct GNUNET_NETWORK_Handle *desc, 172GNUNET_NETWORK_socket_bind(struct GNUNET_NETWORK_Handle *desc,
177 const struct sockaddr *address, 173 const struct sockaddr *address,
178 socklen_t address_len); 174 socklen_t address_len);
179 175
180/** 176/**
181 * Close a socket. 177 * Close a socket.
@@ -184,7 +180,7 @@ GNUNET_NETWORK_socket_bind (struct GNUNET_NETWORK_Handle *desc,
184 * @return #GNUNET_OK on success, #GNUNET_SYSERR otherwise 180 * @return #GNUNET_OK on success, #GNUNET_SYSERR otherwise
185 */ 181 */
186int 182int
187GNUNET_NETWORK_socket_close (struct GNUNET_NETWORK_Handle *desc); 183GNUNET_NETWORK_socket_close(struct GNUNET_NETWORK_Handle *desc);
188 184
189 185
190/** 186/**
@@ -193,7 +189,7 @@ GNUNET_NETWORK_socket_close (struct GNUNET_NETWORK_Handle *desc);
193 * @param desc socket 189 * @param desc socket
194 */ 190 */
195void 191void
196GNUNET_NETWORK_socket_free_memory_only_ (struct GNUNET_NETWORK_Handle *desc); 192GNUNET_NETWORK_socket_free_memory_only_(struct GNUNET_NETWORK_Handle *desc);
197 193
198 194
199/** 195/**
@@ -205,9 +201,9 @@ GNUNET_NETWORK_socket_free_memory_only_ (struct GNUNET_NETWORK_Handle *desc);
205 * @return #GNUNET_OK on success, #GNUNET_SYSERR otherwise 201 * @return #GNUNET_OK on success, #GNUNET_SYSERR otherwise
206 */ 202 */
207int 203int
208GNUNET_NETWORK_socket_connect (const struct GNUNET_NETWORK_Handle *desc, 204GNUNET_NETWORK_socket_connect(const struct GNUNET_NETWORK_Handle *desc,
209 const struct sockaddr *address, 205 const struct sockaddr *address,
210 socklen_t address_len); 206 socklen_t address_len);
211 207
212 208
213/** 209/**
@@ -221,11 +217,11 @@ GNUNET_NETWORK_socket_connect (const struct GNUNET_NETWORK_Handle *desc,
221 * @return #GNUNET_OK on success, #GNUNET_SYSERR otherwise 217 * @return #GNUNET_OK on success, #GNUNET_SYSERR otherwise
222 */ 218 */
223int 219int
224GNUNET_NETWORK_socket_getsockopt (const struct GNUNET_NETWORK_Handle *desc, 220GNUNET_NETWORK_socket_getsockopt(const struct GNUNET_NETWORK_Handle *desc,
225 int level, 221 int level,
226 int optname, 222 int optname,
227 void *optval, 223 void *optval,
228 socklen_t *optlen); 224 socklen_t *optlen);
229 225
230 226
231/** 227/**
@@ -236,8 +232,8 @@ GNUNET_NETWORK_socket_getsockopt (const struct GNUNET_NETWORK_Handle *desc,
236 * @return #GNUNET_OK on success, #GNUNET_SYSERR otherwise 232 * @return #GNUNET_OK on success, #GNUNET_SYSERR otherwise
237 */ 233 */
238int 234int
239GNUNET_NETWORK_socket_listen (const struct GNUNET_NETWORK_Handle *desc, 235GNUNET_NETWORK_socket_listen(const struct GNUNET_NETWORK_Handle *desc,
240 int backlog); 236 int backlog);
241 237
242 238
243/** 239/**
@@ -247,7 +243,7 @@ GNUNET_NETWORK_socket_listen (const struct GNUNET_NETWORK_Handle *desc,
247 * @returns #GNUNET_SYSERR if no data is available, or on error! 243 * @returns #GNUNET_SYSERR if no data is available, or on error!
248 */ 244 */
249ssize_t 245ssize_t
250GNUNET_NETWORK_socket_recvfrom_amount (const struct GNUNET_NETWORK_Handle *desc); 246GNUNET_NETWORK_socket_recvfrom_amount(const struct GNUNET_NETWORK_Handle *desc);
251 247
252 248
253/** 249/**
@@ -261,11 +257,11 @@ GNUNET_NETWORK_socket_recvfrom_amount (const struct GNUNET_NETWORK_Handle *desc)
261 * @param addrlen length of the addr 257 * @param addrlen length of the addr
262 */ 258 */
263ssize_t 259ssize_t
264GNUNET_NETWORK_socket_recvfrom (const struct GNUNET_NETWORK_Handle *desc, 260GNUNET_NETWORK_socket_recvfrom(const struct GNUNET_NETWORK_Handle *desc,
265 void *buffer, 261 void *buffer,
266 size_t length, 262 size_t length,
267 struct sockaddr *src_addr, 263 struct sockaddr *src_addr,
268 socklen_t *addrlen); 264 socklen_t *addrlen);
269 265
270 266
271/** 267/**
@@ -277,9 +273,9 @@ GNUNET_NETWORK_socket_recvfrom (const struct GNUNET_NETWORK_Handle *desc,
277 * @return number of bytes read 273 * @return number of bytes read
278 */ 274 */
279ssize_t 275ssize_t
280GNUNET_NETWORK_socket_recv (const struct GNUNET_NETWORK_Handle *desc, 276GNUNET_NETWORK_socket_recv(const struct GNUNET_NETWORK_Handle *desc,
281 void *buffer, 277 void *buffer,
282 size_t length); 278 size_t length);
283 279
284 280
285/** 281/**
@@ -292,10 +288,10 @@ GNUNET_NETWORK_socket_recv (const struct GNUNET_NETWORK_Handle *desc,
292 * @return number of selected sockets, #GNUNET_SYSERR on error 288 * @return number of selected sockets, #GNUNET_SYSERR on error
293 */ 289 */
294int 290int
295GNUNET_NETWORK_socket_select (struct GNUNET_NETWORK_FDSet *rfds, 291GNUNET_NETWORK_socket_select(struct GNUNET_NETWORK_FDSet *rfds,
296 struct GNUNET_NETWORK_FDSet *wfds, 292 struct GNUNET_NETWORK_FDSet *wfds,
297 struct GNUNET_NETWORK_FDSet *efds, 293 struct GNUNET_NETWORK_FDSet *efds,
298 struct GNUNET_TIME_Relative timeout); 294 struct GNUNET_TIME_Relative timeout);
299 295
300 296
301/** 297/**
@@ -307,9 +303,9 @@ GNUNET_NETWORK_socket_select (struct GNUNET_NETWORK_FDSet *rfds,
307 * @return number of bytes sent, #GNUNET_SYSERR on error 303 * @return number of bytes sent, #GNUNET_SYSERR on error
308 */ 304 */
309ssize_t 305ssize_t
310GNUNET_NETWORK_socket_send (const struct GNUNET_NETWORK_Handle *desc, 306GNUNET_NETWORK_socket_send(const struct GNUNET_NETWORK_Handle *desc,
311 const void *buffer, 307 const void *buffer,
312 size_t length); 308 size_t length);
313 309
314 310
315/** 311/**
@@ -324,11 +320,11 @@ GNUNET_NETWORK_socket_send (const struct GNUNET_NETWORK_Handle *desc,
324 * @return number of bytes sent, #GNUNET_SYSERR on error 320 * @return number of bytes sent, #GNUNET_SYSERR on error
325 */ 321 */
326ssize_t 322ssize_t
327GNUNET_NETWORK_socket_sendto (const struct GNUNET_NETWORK_Handle *desc, 323GNUNET_NETWORK_socket_sendto(const struct GNUNET_NETWORK_Handle *desc,
328 const void *message, 324 const void *message,
329 size_t length, 325 size_t length,
330 const struct sockaddr *dest_addr, 326 const struct sockaddr *dest_addr,
331 socklen_t dest_len); 327 socklen_t dest_len);
332 328
333 329
334/** 330/**
@@ -342,11 +338,11 @@ GNUNET_NETWORK_socket_sendto (const struct GNUNET_NETWORK_Handle *desc,
342 * @return #GNUNET_OK on success, #GNUNET_SYSERR otherwise 338 * @return #GNUNET_OK on success, #GNUNET_SYSERR otherwise
343 */ 339 */
344int 340int
345GNUNET_NETWORK_socket_setsockopt (struct GNUNET_NETWORK_Handle *fd, 341GNUNET_NETWORK_socket_setsockopt(struct GNUNET_NETWORK_Handle *fd,
346 int level, 342 int level,
347 int option_name, 343 int option_name,
348 const void *option_value, 344 const void *option_value,
349 socklen_t option_len); 345 socklen_t option_len);
350 346
351 347
352/** 348/**
@@ -357,8 +353,8 @@ GNUNET_NETWORK_socket_setsockopt (struct GNUNET_NETWORK_Handle *fd,
357 * @return #GNUNET_OK on success, #GNUNET_SYSERR otherwise 353 * @return #GNUNET_OK on success, #GNUNET_SYSERR otherwise
358 */ 354 */
359int 355int
360GNUNET_NETWORK_socket_shutdown (struct GNUNET_NETWORK_Handle *desc, 356GNUNET_NETWORK_socket_shutdown(struct GNUNET_NETWORK_Handle *desc,
361 int how); 357 int how);
362 358
363 359
364/** 360/**
@@ -371,7 +367,7 @@ GNUNET_NETWORK_socket_shutdown (struct GNUNET_NETWORK_Handle *desc,
371 * @return #GNUNET_OK on success, #GNUNET_SYSERR otherwise 367 * @return #GNUNET_OK on success, #GNUNET_SYSERR otherwise
372 */ 368 */
373int 369int
374GNUNET_NETWORK_socket_disable_corking (struct GNUNET_NETWORK_Handle *desc); 370GNUNET_NETWORK_socket_disable_corking(struct GNUNET_NETWORK_Handle *desc);
375 371
376 372
377/** 373/**
@@ -385,9 +381,9 @@ GNUNET_NETWORK_socket_disable_corking (struct GNUNET_NETWORK_Handle *desc);
385 * @return new socket, NULL on error 381 * @return new socket, NULL on error
386 */ 382 */
387struct GNUNET_NETWORK_Handle * 383struct GNUNET_NETWORK_Handle *
388GNUNET_NETWORK_socket_create (int domain, 384GNUNET_NETWORK_socket_create(int domain,
389 int type, 385 int type,
390 int protocol); 386 int protocol);
391 387
392 388
393/** 389/**
@@ -396,7 +392,7 @@ GNUNET_NETWORK_socket_create (int domain,
396 * @param fds fd set to clear 392 * @param fds fd set to clear
397 */ 393 */
398void 394void
399GNUNET_NETWORK_fdset_zero (struct GNUNET_NETWORK_FDSet *fds); 395GNUNET_NETWORK_fdset_zero(struct GNUNET_NETWORK_FDSet *fds);
400 396
401 397
402/** 398/**
@@ -406,8 +402,8 @@ GNUNET_NETWORK_fdset_zero (struct GNUNET_NETWORK_FDSet *fds);
406 * @param desc socket to add 402 * @param desc socket to add
407 */ 403 */
408void 404void
409GNUNET_NETWORK_fdset_set (struct GNUNET_NETWORK_FDSet *fds, 405GNUNET_NETWORK_fdset_set(struct GNUNET_NETWORK_FDSet *fds,
410 const struct GNUNET_NETWORK_Handle *desc); 406 const struct GNUNET_NETWORK_Handle *desc);
411 407
412 408
413#if WINDOWS 409#if WINDOWS
@@ -418,8 +414,8 @@ GNUNET_NETWORK_fdset_set (struct GNUNET_NETWORK_FDSet *fds,
418 * @param h the file handle to add 414 * @param h the file handle to add
419 */ 415 */
420void 416void
421GNUNET_NETWORK_fdset_handle_set_native_w32_handle (struct GNUNET_NETWORK_FDSet *fds, 417GNUNET_NETWORK_fdset_handle_set_native_w32_handle(struct GNUNET_NETWORK_FDSet *fds,
422 HANDLE h); 418 HANDLE h);
423#endif 419#endif
424 420
425 421
@@ -431,8 +427,8 @@ GNUNET_NETWORK_fdset_handle_set_native_w32_handle (struct GNUNET_NETWORK_FDSet *
431 * @return #GNUNET_YES if the socket is in the set 427 * @return #GNUNET_YES if the socket is in the set
432 */ 428 */
433int 429int
434GNUNET_NETWORK_fdset_isset (const struct GNUNET_NETWORK_FDSet *fds, 430GNUNET_NETWORK_fdset_isset(const struct GNUNET_NETWORK_FDSet *fds,
435 const struct GNUNET_NETWORK_Handle *desc); 431 const struct GNUNET_NETWORK_Handle *desc);
436 432
437 433
438/** 434/**
@@ -442,8 +438,8 @@ GNUNET_NETWORK_fdset_isset (const struct GNUNET_NETWORK_FDSet *fds,
442 * @param src the fd set to add from 438 * @param src the fd set to add from
443 */ 439 */
444void 440void
445GNUNET_NETWORK_fdset_add (struct GNUNET_NETWORK_FDSet *dst, 441GNUNET_NETWORK_fdset_add(struct GNUNET_NETWORK_FDSet *dst,
446 const struct GNUNET_NETWORK_FDSet *src); 442 const struct GNUNET_NETWORK_FDSet *src);
447 443
448 444
449/** 445/**
@@ -453,8 +449,8 @@ GNUNET_NETWORK_fdset_add (struct GNUNET_NETWORK_FDSet *dst,
453 * @param from source 449 * @param from source
454 */ 450 */
455void 451void
456GNUNET_NETWORK_fdset_copy (struct GNUNET_NETWORK_FDSet *to, 452GNUNET_NETWORK_fdset_copy(struct GNUNET_NETWORK_FDSet *to,
457 const struct GNUNET_NETWORK_FDSet *from); 453 const struct GNUNET_NETWORK_FDSet *from);
458 454
459 455
460/** 456/**
@@ -464,7 +460,7 @@ GNUNET_NETWORK_fdset_copy (struct GNUNET_NETWORK_FDSet *to,
464 * @return POSIX file descriptor 460 * @return POSIX file descriptor
465 */ 461 */
466int 462int
467GNUNET_NETWORK_get_fd (const struct GNUNET_NETWORK_Handle *desc); 463GNUNET_NETWORK_get_fd(const struct GNUNET_NETWORK_Handle *desc);
468 464
469 465
470/** 466/**
@@ -474,7 +470,7 @@ GNUNET_NETWORK_get_fd (const struct GNUNET_NETWORK_Handle *desc);
474 * @return POSIX file descriptor 470 * @return POSIX file descriptor
475 */ 471 */
476struct sockaddr* 472struct sockaddr*
477GNUNET_NETWORK_get_addr (const struct GNUNET_NETWORK_Handle *desc); 473GNUNET_NETWORK_get_addr(const struct GNUNET_NETWORK_Handle *desc);
478 474
479 475
480/** 476/**
@@ -484,7 +480,7 @@ GNUNET_NETWORK_get_addr (const struct GNUNET_NETWORK_Handle *desc);
484 * @return socklen_t for sockaddr 480 * @return socklen_t for sockaddr
485 */ 481 */
486socklen_t 482socklen_t
487GNUNET_NETWORK_get_addrlen (const struct GNUNET_NETWORK_Handle *desc); 483GNUNET_NETWORK_get_addrlen(const struct GNUNET_NETWORK_Handle *desc);
488 484
489 485
490/** 486/**
@@ -495,9 +491,9 @@ GNUNET_NETWORK_get_addrlen (const struct GNUNET_NETWORK_Handle *desc);
495 * @param nfds the biggest socket number in from + 1 491 * @param nfds the biggest socket number in from + 1
496 */ 492 */
497void 493void
498GNUNET_NETWORK_fdset_copy_native (struct GNUNET_NETWORK_FDSet *to, 494GNUNET_NETWORK_fdset_copy_native(struct GNUNET_NETWORK_FDSet *to,
499 const fd_set *from, 495 const fd_set *from,
500 int nfds); 496 int nfds);
501 497
502 498
503/** 499/**
@@ -507,8 +503,8 @@ GNUNET_NETWORK_fdset_copy_native (struct GNUNET_NETWORK_FDSet *to,
507 * @param nfd native FD to set 503 * @param nfd native FD to set
508 */ 504 */
509void 505void
510GNUNET_NETWORK_fdset_set_native (struct GNUNET_NETWORK_FDSet *to, 506GNUNET_NETWORK_fdset_set_native(struct GNUNET_NETWORK_FDSet *to,
511 int nfd); 507 int nfd);
512 508
513 509
514/** 510/**
@@ -519,8 +515,8 @@ GNUNET_NETWORK_fdset_set_native (struct GNUNET_NETWORK_FDSet *to,
519 * @return #GNUNET_YES if to contains nfd 515 * @return #GNUNET_YES if to contains nfd
520 */ 516 */
521int 517int
522GNUNET_NETWORK_fdset_test_native (const struct GNUNET_NETWORK_FDSet *to, 518GNUNET_NETWORK_fdset_test_native(const struct GNUNET_NETWORK_FDSet *to,
523 int nfd); 519 int nfd);
524 520
525 521
526/** 522/**
@@ -530,8 +526,8 @@ GNUNET_NETWORK_fdset_test_native (const struct GNUNET_NETWORK_FDSet *to,
530 * @param h the file handle to add 526 * @param h the file handle to add
531 */ 527 */
532void 528void
533GNUNET_NETWORK_fdset_handle_set (struct GNUNET_NETWORK_FDSet *fds, 529GNUNET_NETWORK_fdset_handle_set(struct GNUNET_NETWORK_FDSet *fds,
534 const struct GNUNET_DISK_FileHandle *h); 530 const struct GNUNET_DISK_FileHandle *h);
535 531
536 532
537/** 533/**
@@ -542,8 +538,8 @@ GNUNET_NETWORK_fdset_handle_set (struct GNUNET_NETWORK_FDSet *fds,
542 * @param h the file handle to add 538 * @param h the file handle to add
543 */ 539 */
544void 540void
545GNUNET_NETWORK_fdset_handle_set_first (struct GNUNET_NETWORK_FDSet *fds, 541GNUNET_NETWORK_fdset_handle_set_first(struct GNUNET_NETWORK_FDSet *fds,
546 const struct GNUNET_DISK_FileHandle *h); 542 const struct GNUNET_DISK_FileHandle *h);
547 543
548 544
549/** 545/**
@@ -554,8 +550,8 @@ GNUNET_NETWORK_fdset_handle_set_first (struct GNUNET_NETWORK_FDSet *fds,
554 * @return #GNUNET_YES if the file handle is part of the set 550 * @return #GNUNET_YES if the file handle is part of the set
555 */ 551 */
556int 552int
557GNUNET_NETWORK_fdset_handle_isset (const struct GNUNET_NETWORK_FDSet *fds, 553GNUNET_NETWORK_fdset_handle_isset(const struct GNUNET_NETWORK_FDSet *fds,
558 const struct GNUNET_DISK_FileHandle *h); 554 const struct GNUNET_DISK_FileHandle *h);
559 555
560 556
561/** 557/**
@@ -566,8 +562,8 @@ GNUNET_NETWORK_fdset_handle_isset (const struct GNUNET_NETWORK_FDSet *fds,
566 * @return #GNUNET_YES if they do overlap, #GNUNET_NO otherwise 562 * @return #GNUNET_YES if they do overlap, #GNUNET_NO otherwise
567 */ 563 */
568int 564int
569GNUNET_NETWORK_fdset_overlap (const struct GNUNET_NETWORK_FDSet *fds1, 565GNUNET_NETWORK_fdset_overlap(const struct GNUNET_NETWORK_FDSet *fds1,
570 const struct GNUNET_NETWORK_FDSet *fds2); 566 const struct GNUNET_NETWORK_FDSet *fds2);
571 567
572 568
573/** 569/**
@@ -576,7 +572,7 @@ GNUNET_NETWORK_fdset_overlap (const struct GNUNET_NETWORK_FDSet *fds1,
576 * @return a new fd set 572 * @return a new fd set
577 */ 573 */
578struct GNUNET_NETWORK_FDSet * 574struct GNUNET_NETWORK_FDSet *
579GNUNET_NETWORK_fdset_create (void); 575GNUNET_NETWORK_fdset_create(void);
580 576
581 577
582/** 578/**
@@ -585,7 +581,7 @@ GNUNET_NETWORK_fdset_create (void);
585 * @param fds fd set 581 * @param fds fd set
586 */ 582 */
587void 583void
588GNUNET_NETWORK_fdset_destroy (struct GNUNET_NETWORK_FDSet *fds); 584GNUNET_NETWORK_fdset_destroy(struct GNUNET_NETWORK_FDSet *fds);
589 585
590 586
591/** 587/**
@@ -596,8 +592,8 @@ GNUNET_NETWORK_fdset_destroy (struct GNUNET_NETWORK_FDSet *fds);
596 * @return #GNUNET_OK if the port is available, #GNUNET_NO if not 592 * @return #GNUNET_OK if the port is available, #GNUNET_NO if not
597 */ 593 */
598int 594int
599GNUNET_NETWORK_test_port_free (int ipproto, 595GNUNET_NETWORK_test_port_free(int ipproto,
600 uint16_t port); 596 uint16_t port);
601 597
602 598
603#if 0 /* keep Emacsens' auto-indent happy */ 599#if 0 /* keep Emacsens' auto-indent happy */