Browse Source

Merge commit 'ae4ee34' into update_avalon_20130524

Luke Dashjr 12 years ago
parent
commit
eadb8d967d
1 changed files with 2 additions and 2 deletions
  1. 2 2
      util.c

+ 2 - 2
util.c

@@ -1136,7 +1136,7 @@ static enum send_ret __stratum_send(struct pool *pool, char *s, ssize_t len)
 	len++;
 
 	while (len > 0 ) {
-		struct timeval timeout = {0, 0};
+		struct timeval timeout = {1, 0};
 		ssize_t sent;
 		fd_set wd;
 
@@ -1203,7 +1203,7 @@ static bool socket_full(struct pool *pool, bool wait)
 	if (wait)
 		timeout.tv_sec = 60;
 	else
-		timeout.tv_sec = 0;
+		timeout.tv_sec = 1;
 	if (select(sock + 1, &rd, NULL, NULL, &timeout) > 0)
 		return true;
 	return false;