# HG changeset patch # User Adam Chlipala # Date 1295821671 18000 # Node ID d0786ff9bb22e9641f850da0f461d77598e5020c # Parent a8606c1cfe87402fde1ddc2a7b73f40710440a87 Fix detection of POSTs to error pages diff -r a8606c1cfe87 -r d0786ff9bb22 src/c/request.c --- a/src/c/request.c Sun Jan 23 15:49:35 2011 -0500 +++ b/src/c/request.c Sun Jan 23 17:27:51 2011 -0500 @@ -200,6 +200,7 @@ int had_error = 0; char errmsg[ERROR_BUF_LEN]; + uw_reset(ctx); rc->queryString[0] = 0; for (s = path; *s; ++s) { diff -r a8606c1cfe87 -r d0786ff9bb22 src/c/urweb.c --- a/src/c/urweb.c Sun Jan 23 15:49:35 2011 -0500 +++ b/src/c/urweb.c Sun Jan 23 17:27:51 2011 -0500 @@ -590,7 +590,7 @@ ctx->cur_container = NULL; ctx->used_transactionals = 0; ctx->script_header = ""; - ctx->isPost = ctx->hasPostBody = 0; + ctx->hasPostBody = 0; ctx->queryString = NULL; } @@ -605,6 +605,7 @@ memset(ctx->inputs, 0, ctx->app->inputs_len * sizeof(input)); memset(ctx->subinputs, 0, ctx->n_subinputs * sizeof(input)); ctx->used_subinputs = 0; + ctx->isPost = 0; } failure_kind uw_begin_init(uw_context ctx) {