0c606fe1eafe250a7ad5aaf67c3c46690f787618 galt Fri Sep 14 16:25:31 2012 -0700 making tcp connect timeout be a define constant diff --git src/lib/net.c src/lib/net.c index e05fff6..e61fc90 100644 --- src/lib/net.c +++ src/lib/net.c @@ -273,31 +273,31 @@ if (fcntl(sd, F_SETFL, fcntlFlags) < 0) { warn("Error fcntl(..., F_SETFL) (%s)", strerror(errno)); close(sd); return -1; } return sd; } int netConnect(char *hostName, int port) /* Start connection with a server. */ { -return netConnectWithTimeout(hostName, port, 10000); // 10 seconds connect timeout +return netConnectWithTimeout(hostName, port, DEFAULTCONNECTTIMEOUTMSEC); // 10 seconds connect timeout } int netMustConnect(char *hostName, int port) /* Start connection with server or die. */ { int sd = netConnect(hostName, port); if (sd < 0) noWarnAbort(); return sd; } int netMustConnectTo(char *hostName, char *portName) /* Start connection with a server and a port that needs to be converted to integer */ { if (!isdigit(portName[0]))