BUG/MINOR: contrib/spoa_example: Don't reset the status code during disconnect

When the connection is closed by HAProxy, the status code provided in the
DISCONNECT frame is lost. By retransmitting it in the agent's reply, we are sure
to have it in the SPOE logs.

This patch may be backported in 1.8.
This commit is contained in:
Christopher Faulet 2018-05-31 15:59:32 +02:00 committed by Willy Tarreau
parent 6381650516
commit b47e438593
1 changed files with 0 additions and 1 deletions

View File

@ -1474,7 +1474,6 @@ read_frame_cb(evutil_socket_t fd, short events, void *arg)
if (client->status_code != SPOE_FRM_ERR_NONE) if (client->status_code != SPOE_FRM_ERR_NONE)
LOG(client->worker, "<%lu> Peer closed connection: %s", LOG(client->worker, "<%lu> Peer closed connection: %s",
client->id, spoe_frm_err_reasons[client->status_code]); client->id, spoe_frm_err_reasons[client->status_code]);
client->status_code = SPOE_FRM_ERR_NONE;
goto disconnect; goto disconnect;
} }