struct addrinfo;
struct evhttp_request;
+/* Indicates an unknown request method. */
+#define _EVHTTP_REQ_UNKNOWN (1<<15)
+
enum evhttp_connection_state {
EVCON_DISCONNECTED, /**< not currently connected not trying either*/
EVCON_CONNECTING, /**< tries to currently connect */
} else if (strcmp(method, "PATCH") == 0) {
req->type = EVHTTP_REQ_PATCH;
} else {
+ req->type = _EVHTTP_REQ_UNKNOWN;
event_debug(("%s: bad method %s on request %p from %s",
__func__, method, req, req->remote_host));
- return (-1);
+ /* No error yet; we'll give a better error later when
+ * we see that req->type is unsupported. */
}
if (strcmp(version, "HTTP/1.0") == 0) {