X-Git-Url: https://arthur.barton.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fngircd%2Fio.h;h=556d752cab50b17accae64ac9824d5657c468c60;hb=49b2d0ec98d001fbc8eedd5a183d66974f70fd52;hp=3890bcc7df8111ead63749b1c1d844e1dde22e7c;hpb=7eca418465cf3c74c7aee6dfc9a2ab9ba7fbfcfe;p=ngircd-alex.git diff --git a/src/ngircd/io.h b/src/ngircd/io.h index 3890bcc7..556d752c 100644 --- a/src/ngircd/io.h +++ b/src/ngircd/io.h @@ -4,27 +4,29 @@ * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * Please read the file COPYING, README and AUTHORS for more information. - * - * I/O abstraction interface header - * - * $Id: io.h,v 1.1 2005/07/07 18:38:35 fw Exp $ */ -#ifndef io_H_inclucded +#ifndef io_H_included #define io_H_included +/** + * @file + * I/O abstraction interface (header) + */ + #include "portab.h" #include #define IO_WANTREAD 1 #define IO_WANTWRITE 2 -/* init library. sets up epoll/kqueue descriptors and tries to allocate space for ioevlen file descriptors. - ioevlen is just the _initial_ size, not a limit. */ +/* init library. + sets up epoll/kqueue descriptors and tries to allocate space for ioevlen + file descriptors. ioevlen is just the _initial_ size, not a limit. */ bool io_library_init PARAMS((unsigned int ioevlen)); /* shutdown and free all internal data structures */ -bool io_library_shutdown PARAMS((void)); +void io_library_shutdown PARAMS((void)); /* add fd to internal set, enable readability check, set callback */ bool io_event_create PARAMS((int fd, short what, void (*cbfunc)(int, short))); @@ -44,6 +46,9 @@ bool io_close PARAMS((int fd)); /* set O_NONBLOCK */ bool io_setnonblock PARAMS((int fd)); +/* set O_CLOEXEC */ +bool io_setcloexec PARAMS((int fd)); + /* watch fds for activity */ int io_dispatch PARAMS((struct timeval *tv));