mirror of
https://github.com/haproxy/haproxy.git
synced 2026-02-23 01:42:05 -05:00
BUG/MEDIUM: checks: report handshake failures
Up to now, only data layer failures were reported to the task, but if a handshake failed from the beginning, the error was not reported as a failure.
This commit is contained in:
parent
9a92cd5985
commit
6c560da279
1 changed files with 5 additions and 1 deletions
|
|
@ -1183,8 +1183,12 @@ static int wake_srv_chk(struct connection *conn)
|
||||||
{
|
{
|
||||||
struct server *s = conn->owner;
|
struct server *s = conn->owner;
|
||||||
|
|
||||||
if (unlikely(conn->flags & CO_FL_ERROR))
|
if (unlikely(conn->flags & CO_FL_ERROR)) {
|
||||||
|
/* Note that we might as well have been woken up by a handshake handler */
|
||||||
|
s->result |= SRV_CHK_FAILED;
|
||||||
|
__conn_data_stop_both(conn);
|
||||||
task_wakeup(s->check.task, TASK_WOKEN_IO);
|
task_wakeup(s->check.task, TASK_WOKEN_IO);
|
||||||
|
}
|
||||||
|
|
||||||
if (s->result & (SRV_CHK_FAILED|SRV_CHK_PASSED))
|
if (s->result & (SRV_CHK_FAILED|SRV_CHK_PASSED))
|
||||||
conn_full_close(conn);
|
conn_full_close(conn);
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue