Hi.
I'm using 'select' to detect which client is sending information to
the server. So I got the following code:
==============================
while (TRUE)
{
FD_ZERO (&clients_fds); /* This call to FD_ZERO is here to update
the info about active clients in every loop*/
for (i=0; i < MAX_CONNECTIONS; i++)
if (client_sockets[i].socket > 0) FD_SET
(client_sockets[i].socket, &clients_fds);
numSelected = select (max_fd (client_sockets)+1, &clients_fds,
(fd_set *) 0, (fd_set *) 0, (struct timeval *) 0);
...
}
===============================
Well, the question is what am I doing wrong because 'select' never
returns even though client is calling 'sock_write' in an infinite loop
without errors!!! :?
Thanks again and regards from Spain. :)
Moises Navarro.