我尝试使用keep-alive连接猫鼬,但似乎猫鼬首先关闭了连接。
我更改了 embed.c 以发回连接:keep-alive。响应后连接仍然关闭。
border@ubuntu:~$ nc 127.0.0.1 9999
GET /test_get_request_info HTTP/1.1
Connection: keep-alive
HTTP/1.1 200 OK
Content-Type: text/plain
Connection: keep-alive
Method: [GET]
URI: [/test_get_request_info]
HTTP version: [1/1]
HTTP header [Connection]: [keep-alive]
Query string: []
POST data: []
Remote IP: [2130706433]
Remote port: [56719]
Remote user: [] <-----------------connection closed, nc returns
border@ubuntu:~$