bug#36350: [2.2.5] ‘read-headers’ blocks, thereby breaking web servers

2019-06-24 Thread Dan Frumin
By the way, I've just tested the web server in Google Chrome, and it works fine! I was told that a (potential) reason for that is that Chrome sends TCP FIN to the server, which closes the socket for reading, and then `lookahead-char` sees eof. Best, Dan

bug#36350: [2.2.5] ‘read-headers’ blocks, thereby breaking web servers

2019-06-24 Thread Dan Frumin
I believe that `(lookahead-char port)` really blocks when the client has finished sending the request and there is no more data from `port` to consume. If I understand it correctly, then per HTTP/1.1 [1] the request ends with CRLF at the last line, and then comes the message. So I we have read an