3 % (c) The GRASP/AQUA Project, Glasgow University, 1996
5 \subsection[listenSocket.lc]{Indicate willingness to receive connections}
10 #define NON_POSIX_SOURCE
12 #include "ghcSockets.h"
15 listenSocket(I_ sockfd, I_ backlog)
19 while ((rc = listen((int) sockfd, (int) backlog)) < 0) {
27 ghc_errtype = ERR_INVALIDARGUMENT;
28 ghc_errstr = "Not a valid descriptor";
31 ghc_errtype = ERR_INVALIDARGUMENT;
32 ghc_errstr = "Descriptor not a socket";
35 ghc_errtype = ERR_INVALIDARGUMENT;
36 ghc_errstr = "Socket not of type that supports listen";