File tree Expand file tree Collapse file tree 1 file changed +1
-5
lines changed
Expand file tree Collapse file tree 1 file changed +1
-5
lines changed Original file line number Diff line number Diff line change @@ -139,22 +139,18 @@ void Connection::ListenForRequests() noexcept {
139139 << " Received " << pending_data_size_ << " byte(s) from " << Getpeername () << " on fd " << Fd ();
140140 }
141141
142- bool should_stop_accepting_requests = false ;
143142 if (!request_parser.Parse ({pending_data_.data (), pending_data_size_})) {
144143 LOG_DEBUG () << " Malformed request from " << Getpeername () << " on fd " << Fd ();
145144
146145 // Stop accepting new requests, send previous answers.
147- should_stop_accepting_requests = true ;
146+ is_accepting_requests_ = false ;
148147 }
149148 pending_data_size_ = 0 ;
150149
151150 for (auto && request : pending_requests) {
152151 ProcessRequest (std::move (request));
153152 }
154153 pending_requests.resize (0 );
155- if (should_stop_accepting_requests) {
156- is_accepting_requests_ = false ;
157- }
158154 }
159155
160156 LOG_TRACE () << " Gracefully stopping ListenForRequests()" ;
You can’t perform that action at this time.
0 commit comments