res_http_websocket: Forcefully terminate on write errors.
authorJoshua Colp <jcolp@digium.com>
Tue, 11 Aug 2015 10:24:30 +0000 (07:24 -0300)
committerJoshua Colp <jcolp@digium.com>
Tue, 11 Aug 2015 10:28:20 +0000 (07:28 -0300)
commitb9bd3c1435cb1e7b09851de2c7dcc5882bc2f9f4
tree200986b3f77a15e22e3b6d2073d2b94e0fc30f00
parent06b464ab1b7c42e3c1b5b05463d5bc73c112dd76
res_http_websocket: Forcefully terminate on write errors.

The res_http_websocket module will currently attempt to close
the WebSocket connection if fatal cases occur, such as when
attempting to write out data and being unable to. When the
fatal cases occur the code attempts to write a WebSocket close
frame out to have the remote side close the connection. If
writing this fails then the connection is not terminated.

This change forcefully terminates the connection if the
WebSocket is to be closed but is unable to send the close frame.

ASTERISK-25312 #close

Change-Id: I10973086671cc192a76424060d9ec8e688602845
res/res_http_websocket.c