Browse Source

Be far more generous when waiting on read_socket_line

master
Con Kolivas 11 years ago
parent
commit
1a5aa1874d
  1. 4
      src/libckpool.c

4
src/libckpool.c

@ -494,7 +494,7 @@ int read_socket_line(connsock_t *cs)
{ {
char readbuf[PAGESIZE], *eom = NULL; char readbuf[PAGESIZE], *eom = NULL;
size_t buflen = 0, bufofs = 0; size_t buflen = 0, bufofs = 0;
tv_t timeout = {5, 0}; tv_t timeout = {60, 0};
int ret, bufsiz; int ret, bufsiz;
fd_set rd; fd_set rd;
@ -519,7 +519,7 @@ retry:
FD_ZERO(&rd); FD_ZERO(&rd);
FD_SET(cs->fd, &rd); FD_SET(cs->fd, &rd);
timeout.tv_sec = 1; timeout.tv_sec = 5;
timeout.tv_usec = 0; timeout.tv_usec = 0;
ret = select(cs->fd + 1, &rd, NULL, NULL, &timeout); ret = select(cs->fd + 1, &rd, NULL, NULL, &timeout);
if (ret < 0 && interrupted()) if (ret < 0 && interrupted())

Loading…
Cancel
Save