Browse Source

Merge commit '832012f' into cg_merges_20130524b

Luke Dashjr 13 years ago
parent
commit
c067ddb7a6
1 changed files with 4 additions and 0 deletions
  1. 4 0
      util.c

+ 4 - 0
util.c

@@ -1187,7 +1187,11 @@ static enum send_ret __stratum_send(struct pool *pool, char *s, ssize_t len)
 		FD_SET(sock, &wd);
 		FD_SET(sock, &wd);
 		if (select(sock + 1, NULL, &wd, NULL, &timeout) < 1)
 		if (select(sock + 1, NULL, &wd, NULL, &timeout) < 1)
 			return SEND_SELECTFAIL;
 			return SEND_SELECTFAIL;
+#ifndef WIN32
+		sent = send(pool->sock, s + ssent, len, MSG_NOSIGNAL);
+#else
 		sent = send(pool->sock, s + ssent, len, 0);
 		sent = send(pool->sock, s + ssent, len, 0);
+#endif
 		if (sent < 0) {
 		if (sent < 0) {
 			if (!sock_blocks())
 			if (!sock_blocks())
 				return SEND_SENDFAIL;
 				return SEND_SENDFAIL;