Http keep-alive 连接 - 响应分隔符
你好,我正在编写一个自定义 http 服务器。起初,我在一个连接上只有一个请求(连接:关闭),一切正常。但是,一旦我重新制作了 connecton: keep-alive 逻辑(一个连接上有更多请求),我的图像就停止显示。我认为,这可能是http响应分隔符的问题。有吗?或者浏览器如何检测当前的 http 响应是否完成?谢谢
Hi i am writing a custom http server. At first i had only one request at one connection possible(Connection: close), everything was ok. But once i remade it connecton: keep-alive logic(more requests at one connection), my images stopped displaying. I think, it may be a problem with http response delimiters. Are there any? Or how can browser detect, that current http response is complete? thx
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
响应的大小由
Content-Length
标头或使用 分块传输决定编码。The size of the response is guided by the
Content-Length
header or by using Chunked Transfer Encoding.