diff --git a/src/http_act.c b/src/http_act.c index 0653dd59e..495ba55b3 100644 --- a/src/http_act.c +++ b/src/http_act.c @@ -62,8 +62,8 @@ static enum act_return http_action_set_req_line(struct act_rule *rule, struct pr replace->size - replace->data, &rule->arg.http.logfmt); - http_replace_req_line(rule->arg.http.action, replace->area, - replace->data, px, s); + htx_req_replace_stline(rule->arg.http.action, replace->area, + replace->data, px, s); ret = ACT_RET_CONT; @@ -148,12 +148,7 @@ static enum act_return http_action_replace_uri(struct act_rule *rule, struct pro output = alloc_trash_chunk(); if (!replace || !output) goto leave; - - if (IS_HTX_STRM(s)) - uri = htx_sl_req_uri(http_get_stline(htxbuf(&s->req.buf))); - else - uri = ist2(ci_head(&s->req) + s->txn->req.sl.rq.u, s->txn->req.sl.rq.u_l); - + uri = htx_sl_req_uri(http_get_stline(htxbuf(&s->req.buf))); if (!regex_exec_match2(rule->arg.act.p[1], uri.ptr, uri.len, MAX_MATCH, pmatch, 0)) goto leave; @@ -167,7 +162,7 @@ static enum act_return http_action_replace_uri(struct act_rule *rule, struct pro goto leave; /* 3 is the set-uri action */ - http_replace_req_line(3, output->area, len, px, s); + htx_req_replace_stline(3, output->area, len, px, s); ret = ACT_RET_CONT; @@ -220,7 +215,7 @@ static enum act_parse_ret parse_replace_uri(const char **args, int *orig_arg, st static enum act_return action_http_set_status(struct act_rule *rule, struct proxy *px, struct session *sess, struct stream *s, int flags) { - http_set_status(rule->arg.status.code, rule->arg.status.reason, s); + htx_res_set_status(rule->arg.status.code, rule->arg.status.reason, s); return ACT_RET_CONT; }