| 1633 | } |
| 1634 | |
| 1635 | inline void operator()(TCont* c) { |
| 1636 | try { |
| 1637 | TContBIOWatcher w(*IO_, c); |
| 1638 | |
| 1639 | if (IO_->PollReadT(TDuration::Seconds(InputConnections()->UnusedConnKeepaliveTimeout()))) { |
| 1640 | IO_->Close(true); |
| 1641 | return; |
| 1642 | } |
| 1643 | |
| 1644 | IO_->Handshake(); |
| 1645 | THttpInput in(IO_.Get()); |
| 1646 | |
| 1647 | const char sym = *in.FirstLine().data(); |
| 1648 | |
| 1649 | if (sym == 'p' || sym == 'P') { |
| 1650 | Server_->OnRequest(new TPostRequest(in, IO_, Server_)); |
| 1651 | } else { |
| 1652 | Server_->OnRequest(new TGetRequest(in, IO_, Server_)); |
| 1653 | } |
| 1654 | } catch (...) { |
| 1655 | IO_->Close(false); |
| 1656 | } |
| 1657 | |
| 1658 | if (SelfRemove) { |
| 1659 | delete this; |
| 1660 | } |
| 1661 | } |
| 1662 | |
| 1663 | private: |
| 1664 | void DoRun(TCont* c) override { |
nothing calls this directly
no test coverage detected