diff options
author | Valentin Bartenev <vbart@nginx.com> | 2017-12-25 17:04:22 +0300 |
---|---|---|
committer | Valentin Bartenev <vbart@nginx.com> | 2017-12-25 17:04:22 +0300 |
commit | 8830d732614276b015c56fec2fb3cb77de9f8441 (patch) | |
tree | 8d0408cdf4002413d6a9670a3e7025ab02ffd675 /src/nxt_router.c | |
parent | 392abd03e5cbb4f6608403364721b5c1f26d9f06 (diff) | |
download | unit-8830d732614276b015c56fec2fb3cb77de9f8441.tar.gz unit-8830d732614276b015c56fec2fb3cb77de9f8441.tar.bz2 |
HTTP parser: reworked header fields handling.
Diffstat (limited to 'src/nxt_router.c')
-rw-r--r-- | src/nxt_router.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/nxt_router.c b/src/nxt_router.c index 7b52876a..103ba78c 100644 --- a/src/nxt_router.c +++ b/src/nxt_router.c @@ -3327,9 +3327,9 @@ nxt_python_prepare_msg(nxt_task_t *task, nxt_app_request_t *r, NXT_WRITE(&h->content_length); nxt_list_each(field, h->fields) { - RC(nxt_app_msg_write_prefixed_upcase(task, wmsg, - &prefix, &field->name)); - NXT_WRITE(&field->value); + RC(nxt_app_msg_write_prefixed_upcase(task, wmsg, &prefix, field->name, + field->name_length)); + RC(nxt_app_msg_write(task, wmsg, field->value, field->value_length)); } nxt_list_loop; @@ -3431,9 +3431,9 @@ nxt_php_prepare_msg(nxt_task_t *task, nxt_app_request_t *r, } nxt_list_each(field, h->fields) { - RC(nxt_app_msg_write_prefixed_upcase(task, wmsg, - &prefix, &field->name)); - NXT_WRITE(&field->value); + RC(nxt_app_msg_write_prefixed_upcase(task, wmsg, &prefix, field->name, + field->name_length)); + RC(nxt_app_msg_write(task, wmsg, field->value, field->value_length)); } nxt_list_loop; @@ -3511,8 +3511,8 @@ nxt_go_prepare_msg(nxt_task_t *task, nxt_app_request_t *r, nxt_app_wmsg_t *wmsg) RC(nxt_app_msg_write_size(task, wmsg, h->parsed_content_length)); nxt_list_each(field, h->fields) { - NXT_WRITE(&field->name); - NXT_WRITE(&field->value); + RC(nxt_app_msg_write(task, wmsg, field->name, field->name_length)); + RC(nxt_app_msg_write(task, wmsg, field->value, field->value_length)); } nxt_list_loop; |