|
|
@@ -142,11 +142,6 @@ MHD_tls_connection_handle_idle (struct MHD_Connection *connection)
|
|
|
#endif
|
|
|
if (connection->suspended)
|
|
|
return MHD_connection_handle_idle (connection);
|
|
|
- timeout = connection->connection_timeout;
|
|
|
- if ( (timeout != 0) &&
|
|
|
- (timeout <= (MHD_monotonic_sec_counter() - connection->last_activity)))
|
|
|
- MHD_connection_close_ (connection,
|
|
|
- MHD_REQUEST_TERMINATED_TIMEOUT_REACHED);
|
|
|
switch (connection->state)
|
|
|
{
|
|
|
/* on newly created connections we might reach here before any reply has been received */
|
|
|
@@ -158,6 +153,11 @@ MHD_tls_connection_handle_idle (struct MHD_Connection *connection)
|
|
|
default:
|
|
|
return MHD_connection_handle_idle (connection);
|
|
|
}
|
|
|
+ timeout = connection->connection_timeout;
|
|
|
+ if ( (timeout != 0) &&
|
|
|
+ (timeout <= (MHD_monotonic_sec_counter() - connection->last_activity)))
|
|
|
+ MHD_connection_close_ (connection,
|
|
|
+ MHD_REQUEST_TERMINATED_TIMEOUT_REACHED);
|
|
|
#ifdef EPOLL_SUPPORT
|
|
|
return MHD_connection_epoll_update_ (connection);
|
|
|
#else
|