Issue #23834: Fix the default socket timeout

Use -1 second by default, not -1 nanosecond.
This commit is contained in:
Victor Stinner 2015-04-09 10:23:12 +02:00
parent da5cbe65ae
commit 88ed640fc7
2 changed files with 8 additions and 2 deletions

View file

@ -839,7 +839,8 @@ sock_call(PySocketSockObject *s,
/* Initialize a new socket object. */
static _PyTime_t defaulttimeout = -1; /* Default timeout for new sockets */
/* Default timeout for new sockets */
static _PyTime_t defaulttimeout = _PYTIME_FROMSECONDS(-1);
static void
init_sockobject(PySocketSockObject *s,