| 593 | } |
| 594 | |
| 595 | TClientConnection::TClientConnection(const TSocket& s, THttpServer::TImpl* serv, NAddr::IRemoteAddrRef listenerSockAddrRef) |
| 596 | : Socket_(s) |
| 597 | , ListenerSockAddrRef_(listenerSockAddrRef) |
| 598 | , HttpServ_(serv) |
| 599 | { |
| 600 | SetNoDelay(Socket_, true); |
| 601 | |
| 602 | const TDuration& clientTimeout = HttpServ_->Options().ClientTimeout; |
| 603 | if (clientTimeout != TDuration::Zero()) { |
| 604 | SetSocketTimeout(Socket_, (long)clientTimeout.Seconds(), clientTimeout.MilliSecondsOfSecond()); |
| 605 | } |
| 606 | |
| 607 | HttpServ_->IncreaseConnections(); |
| 608 | } |
| 609 | |
| 610 | TClientConnection::~TClientConnection() { |
| 611 | if (!CleanupState_.Closed) { |
nothing calls this directly
no test coverage detected