Getting response of http request without content-length?

前端 未结 2 1405
情书的邮戳
情书的邮戳 2021-02-02 10:14

I have a little program sends http request and gets response with TCP protocol.

My request format;

GET / HTTP/1.0
Host: somewebsite.com
{two new line}
         


        
2条回答
  •  生来不讨喜
    2021-02-02 10:47

    In HTTP/1.0 - server response without content-length is when the stream closes

    In HTTP/1.1 - server response without content-length is when the response is chunked encoded

提交回复
热议问题