| 4285 | } |
| 4286 | |
| 4287 | inline bool expect_content(const Request &req) { |
| 4288 | if (req.method == "POST" || req.method == "PUT" || req.method == "PATCH" || |
| 4289 | req.method == "PRI" || req.method == "DELETE") { |
| 4290 | return true; |
| 4291 | } |
| 4292 | // TODO: check if Content-Length is set |
| 4293 | return false; |
| 4294 | } |
| 4295 | |
| 4296 | inline bool has_crlf(const std::string &s) { |
| 4297 | auto p = s.c_str(); |