Mercurial > hg > nginx-quic
annotate auto/nohave @ 7034:1b068a4e82d8
Added support for trailers in HTTP responses.
Example:
ngx_table_elt_t *h;
h = ngx_list_push(&r->headers_out.trailers);
if (h == NULL) {
return NGX_ERROR;
}
ngx_str_set(&h->key, "Fun");
ngx_str_set(&h->value, "with trailers");
h->hash = ngx_hash_key_lc(h->key.data, h->key.len);
The code above adds "Fun: with trailers" trailer to the response.
Modules that want to emit trailers must set r->expect_trailers = 1
in header filter, otherwise they might not be emitted for HTTP/1.1
responses that aren't already chunked.
This change also adds $sent_trailer_* variables.
Signed-off-by: Piotr Sikora <piotrsikora@google.com>
author | Piotr Sikora <piotrsikora@google.com> |
---|---|
date | Fri, 24 Mar 2017 03:37:34 -0700 |
parents | d620f497c50f |
children |
rev | line source |
---|---|
444
42d11f017717
nginx-0.1.0-2004-09-29-20:00:49 import; remove years from copyright
Igor Sysoev <igor@sysoev.ru>
parents:
298
diff
changeset
|
1 |
42d11f017717
nginx-0.1.0-2004-09-29-20:00:49 import; remove years from copyright
Igor Sysoev <igor@sysoev.ru>
parents:
298
diff
changeset
|
2 # Copyright (C) Igor Sysoev |
4412 | 3 # Copyright (C) Nginx, Inc. |
444
42d11f017717
nginx-0.1.0-2004-09-29-20:00:49 import; remove years from copyright
Igor Sysoev <igor@sysoev.ru>
parents:
298
diff
changeset
|
4 |
298
4a3f18406832
nginx-0.0.3-2004-03-30-10:27:36 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
5 |
4a3f18406832
nginx-0.0.3-2004-03-30-10:27:36 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
6 cat << END >> $NGX_AUTO_CONFIG_H |
4a3f18406832
nginx-0.0.3-2004-03-30-10:27:36 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
7 |
4a3f18406832
nginx-0.0.3-2004-03-30-10:27:36 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
8 #ifndef $have |
4a3f18406832
nginx-0.0.3-2004-03-30-10:27:36 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
9 #define $have 0 |
4a3f18406832
nginx-0.0.3-2004-03-30-10:27:36 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
10 #endif |
4a3f18406832
nginx-0.0.3-2004-03-30-10:27:36 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
11 |
4a3f18406832
nginx-0.0.3-2004-03-30-10:27:36 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
12 END |