Switch server->connect_time from time_t to struct timeval

This means that settings like CONNECT_DELAY and CONNECT_TIMEOUT are compared
against the current time with sub-second resolution.  With the old way, the
delays could be up to a second longer than asked for, which had the effect of
almost doubling the default CONNECT_DELAY value of 1.
This commit is contained in:
Kevin Easton
2015-05-13 23:17:18 +10:00
parent 4ee6c6295b
commit f1c27a4f64
2 changed files with 6 additions and 7 deletions

View File

@@ -155,7 +155,7 @@ typedef struct
int from_server;
#endif
char *orignick;
time_t connect_time;
struct timeval connect_time;
#if defined(HAVE_SSL) && !defined(IN_MODULE)
SSL_CTX* ctx;
int enable_ssl;