Commit ec5c5aec6d5373e47936891c6b8111716d16f3e6

Nick Mathewson 2010-11-23T20:31:28

Handle evhttp PUT/POST requests with an empty body When we call evhttp_get_bodylen() [when transfer-encoding isn't set], having req->ntoread == -1 means that we have no content-length. But a request with no content-length has no body! We were treating the absent content-length as meaning "read till closed", which only holds for replies, not requests. This patch also allows PATCH requests to have a body.