Fix reporting to Consul, report even if we are purely secondary

This commit is contained in:
Vitaliy Filippov
2020-04-17 01:59:06 +03:00
parent 309486d746
commit 2a8e40835e
6 changed files with 39 additions and 16 deletions
+7 -7
View File
@@ -308,12 +308,7 @@ void http_co_t::resume()
// Read response
if (st == 5)
{
if (epoll_events & (EPOLLRDHUP|EPOLLERR))
{
delete this;
return;
}
else if (epoll_events & EPOLLIN)
if (epoll_events & EPOLLIN)
{
if (rbuf.size() != 9000)
rbuf.resize(9000);
@@ -332,7 +327,12 @@ void http_co_t::resume()
};
my_uring_prep_recvmsg(sqe, peer_fd, &msg, 0);
st = 6;
epoll_events = 0;
epoll_events = epoll_events & ~EPOLLIN;
}
else if (epoll_events & (EPOLLRDHUP|EPOLLERR))
{
delete this;
return;
}
}
if (st == 6)