X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=include%2Fsocketengine.h;h=3a15e98c1475cfefd252596c85913754ef4d0812;hb=8f31b0cf2a753cd7b6af8fd1dc730d0693ebeb90;hp=305d389d4bac610e33dd83789b99c95afd7d63ae;hpb=efe77ba63b1e519fc4d563bd9b599277c4bd96e5;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/include/socketengine.h b/include/socketengine.h index 305d389d4..3a15e98c1 100644 --- a/include/socketengine.h +++ b/include/socketengine.h @@ -409,12 +409,11 @@ public: */ static int Accept(EventHandler* fd, sockaddr *addr, socklen_t *addrlen); - /** Abstraction for BSD sockets close(2). - * This function should emulate its namesake system call exactly. - * @param fd This version of the call takes an EventHandler instead of a bare file descriptor. - * @return This method should return exactly the same values as the system call it emulates. + /** Close the underlying fd of an event handler, remove it from the socket engine and set the fd to -1. + * @param eh The EventHandler to close. + * @return 0 on success, a negative value on error */ - static int Close(EventHandler* fd); + static int Close(EventHandler* eh); /** Abstraction for BSD sockets close(2). * This function should emulate its namesake system call exactly.