2
0
Fork 0

Add 100-Continue handling

personal/stbuehler/wip
Stefan Bühler 2008-08-08 19:12:36 +02:00
parent 6dcfc736c2
commit 124e21ee7d
2 changed files with 8 additions and 1 deletions

View File

@ -323,6 +323,14 @@ void connection_state_machine(server *srv, connection *con) {
if (CORE_OPTION(CORE_OPTION_DEBUG_REQUEST_HANDLING)) {
TRACE(srv, "%s", "read request/handle response header");
}
if (con->expect_100_cont) {
if (CORE_OPTION(CORE_OPTION_DEBUG_REQUEST_HANDLING)) {
TRACE(srv, "%s", "send 100 Continue");
}
chunkqueue_append_mem(cq->raw_out, CONST_STR_LEN("HTTP/1.1 100 Continue\r\n\r\n"));
con->expect_100_cont = FALSE;
ev_io_add_events(srv->loop, &con->sock.watcher, EV_WRITE);
}
parse_request_body(srv, con);
/* TODO: call plugin content_handler */
switch (action_execute(srv, con)) {

View File

@ -67,7 +67,6 @@ struct connection {
guint idx; /** index in connection table */
connection_state_t state;
gboolean response_headers_sent, expect_100_cont;
/* TODO: implement expect_100 */
chunkqueue *raw_in, *raw_out;
chunkqueue *in, *out;