确保http请求合法

This commit is contained in:
ziyue 2021-09-03 18:02:31 +08:00
parent 5f2e4ff2c0
commit 246f446142

View File

@ -59,6 +59,8 @@ ssize_t HttpSession::onRecvHeader(const char *header,size_t len) {
}, nullptr);
_parser.Parse(header);
CHECK(_parser.Url()[0] == '/');
urlDecode(_parser);
string cmd = _parser.Method();
auto it = s_func_map.find(cmd);