C: Using select() to write to new client C: Using select() to write to new client unix unix

C: Using select() to write to new client


Seconds after posting this I found the solution. The listening sockets both need to be read from when there is a new client. Only after accepting the connection does the new socket get watched for writing. The socket listening for new connections obviously needs to be read from not written to. Will keep this up for others...