diff options
| author | leo <[email protected]> | 2022-02-10 16:46:40 +0300 | 
|---|---|---|
| committer | Daniil Cherednik <[email protected]> | 2022-02-10 16:46:40 +0300 | 
| commit | 980edcd3304699edf9d4e4d6a656e585028e2a72 (patch) | |
| tree | 139f47f3911484ae9af0eb347b1a88bd6c4bb35f /library/cpp/http/server/http.cpp | |
| parent | b036a557f285146e5e35d4213e29a094ab907bcf (diff) | |
Restoring authorship annotation for <[email protected]>. Commit 1 of 2.
Diffstat (limited to 'library/cpp/http/server/http.cpp')
| -rw-r--r-- | library/cpp/http/server/http.cpp | 28 | 
1 files changed, 14 insertions, 14 deletions
| diff --git a/library/cpp/http/server/http.cpp b/library/cpp/http/server/http.cpp index 128583bdd70..8d1900ef9e3 100644 --- a/library/cpp/http/server/http.cpp +++ b/library/cpp/http/server/http.cpp @@ -22,7 +22,7 @@  #include <cerrno>  #include <cstring>  #include <ctime> - +   #include <sys/stat.h>  #include <sys/types.h> @@ -139,7 +139,7 @@ public:          try {              ((TImpl*)param)->ListenSocket();          } catch (...) { - +           }          return nullptr; @@ -149,7 +149,7 @@ public:          THolder<TClientRequest> obj(Cb_->CreateClient());          obj->Conn_.Reset(c.Release()); - +           return obj;      } @@ -171,7 +171,7 @@ public:      void SaveErrorCode() {          ErrorCode = WSAGetLastError();      } - +       int GetErrorCode() const {          return ErrorCode;      } @@ -218,7 +218,7 @@ public:              ListenThread.Reset(nullptr);          }      } - +       void Stop() {          Shutdown(); @@ -309,7 +309,7 @@ public:              Server_->AddRequestFromSocket(s, TInstant::Now(), SockAddrRef_);          } - +           SOCKET GetSocket() const noexcept {              return S_;          } @@ -338,13 +338,13 @@ public:              return;          } - +           Requests->Start(Options_.nThreads, Options_.MaxQueueSize);          FailRequests->Start(Options_.nFThreads, Options_.MaxFQueueSize);          Cb_->OnListenStart();          ListenerRunningOK = true;          ListenStartEvent.Signal(); - +           TVector<void*> events;          events.resize(1); @@ -378,7 +378,7 @@ public:                  Cb_->OnException();              }          } - +           while (!Reqs.Empty()) {              THolder<TListenSocket> ls(Reqs.PopFront()); @@ -586,20 +586,20 @@ void TClientConnection::OnPollEvent(TInstant now) {              return;          } -    } +    }       THolder<TClientRequest> obj(HttpServ_->CreateRequest(this_));      AcceptMoment = now;      HttpServ_->AddRequest(obj, Reject_); -} - +}  +   void TClientConnection::Activate(TInstant now) noexcept {      HttpServ_->Connections->Erase(this, now);      LastUsed = now;      ++ReceivedRequests; -} - +}  +   void TClientConnection::DeActivate() {      HttpServ_->Connections->Add(this);  } | 
