only report CLIENT_CONNECTION_ERROR once on some paths
In most cases the close api will see it should send the CCE because we are still in the waiting server reply state until the end of the interpretation. Only if we completed the interpretation and moved on to ESTABLISHED do we need to handle sending it ourselves. Signed-off-by: Andy Green <andy.green@linaro.org>
This commit is contained in:
parent
389a4bb9f0
commit
7c15eb1e42
1 changed files with 1 additions and 1 deletions
|
@ -855,7 +855,7 @@ bail3:
|
|||
close_reason = LWS_CLOSE_STATUS_NOSTATUS;
|
||||
|
||||
bail2:
|
||||
if (wsi->protocol) {
|
||||
if (wsi->protocol && wsi->state == LWSS_ESTABLISHED) {
|
||||
if (isErrorCodeReceived && p) {
|
||||
wsi->protocol->callback(wsi,
|
||||
LWS_CALLBACK_CLIENT_CONNECTION_ERROR,
|
||||
|
|
Loading…
Add table
Reference in a new issue