I have this weird thing where in either Chrome or Firefox I test my server that serves .html, then requests a .css and a .js file, however the browser just seems to hang, even though I suspect it’s received those files and they appear to be valid. If I close the connection then both browsers will show the page. My HTTP response looks like:
HTTP/1.1 200 OKrn
Content - Type: text/htmlrn
Content - Length: (the length)rn
rn
/* THE BODY */
If I look in the network tab of the browser it seems that the requests for the html and css and js files are “pending”, however I’ve already sent them through the socket. It’s only when I close the socket that the page loads. What is happening? It can’t be the case the socket.send() is just leaving the data in the buffer without sending it (Nagles algorithm only holds the data if it’s under a certain size AND it has unreceived ACKs).