rem: debug_v("Connection received (new fd=%d)", new_sock);
add: debug_v(("Connection received (new fd=%d)", new_sock));
context: int netcat_socket_accept(int s, int timeout){  fd_set in;  int ret;  static bool timeout_init = FALSE;  static struct timeval timest;  debug_v("netcat_socket_accept(s=%d, timeout=%d)", s, timeout);  /* initialize the select() variables */  FD_ZERO(&in);  FD_SET(s, &in);  if (timeout > 0) {    timest.tv_sec = timeout;    timest.tv_usec = 0;    timeout_init = TRUE;  }  else if (timeout && !timeout_init) {    /* means that timeout is < 0 and timest hasn't been initialized */    timeout = 0;  }  /* now call select(2).  use timest only if we won't wait forever */ call_select:  ret = select(s + 1, &in, NULL, NULL, (timeout ? &timest : NULL));  if (ret < 0) {    /* if the call was interrupted by a signal nothing happens. signal at this       stage ought to be handled externally. */    if (errno == EINTR)      goto call_select;    perror("select(sock_accept)");    exit(EXIT_FAILURE);  }  /* have we got this connection? */  if (FD_ISSET(s, &in)) {    int new_sock;    new_sock = accept(s, NULL, NULL);    debug_v("Connection received (new fd=%d)", new_sock);    /* NOTE: as accept() could fail, new_sock might also be a negative value.       It's application's work to handle the right errno. */    return new_sock;  }  /* since we've got a timeout, the timest is now zero and thus it is like     uninitialized.  Next time assume wait forever. */  timeout_init = FALSE;  /* no connections arrived during the given time. nothing happens */  errno = ETIMEDOUT;  return -1;}