Web Framework to build REST APIs, Webservices or any HTTP endpoint in C language. Can stream large amount of data, integrate JSON data with Jansson, and create websocket services
ulfius_set_websocket_request() adds Connection: Upgrade and Upgrade: websocket headers to request->map_header, but ulfius_websocket_connection_handshake() already emits those headers separately, causing both headers to be duplicated which causes connections to fail (at least to nodejs websocket servers).
ulfius_set_websocket_request() also adds a Content-Length: 0 header but GET-requests do not have a body hence are not supposed to have a Content-Length header.
ulfius_set_websocket_request()
addsConnection: Upgrade
andUpgrade: websocket
headers torequest->map_header
, butulfius_websocket_connection_handshake()
already emits those headers separately, causing both headers to be duplicated which causes connections to fail (at least to nodejs websocket servers).ulfius_set_websocket_request()
also adds aContent-Length: 0
header butGET
-requests do not have a body hence are not supposed to have aContent-Length
header.Fix: