Mercurial > hg > nginx
diff src/http/v2/ngx_http_v2.h @ 6395:ba3c2ca21aa5
HTTP/2: implemented HPACK Huffman encoding for response headers.
This reduces the size of headers by over 30% on average.
Based on the patch by Vlad Krasnov:
http://mailman.nginx.org/pipermail/nginx-devel/2015-December/007682.html
author | Valentin Bartenev <vbart@nginx.com> |
---|---|
date | Thu, 11 Feb 2016 15:35:36 +0300 |
parents | d2dc8bc0394a |
children | 8ec349bb60b2 |
line wrap: on
line diff
--- a/src/http/v2/ngx_http_v2.h +++ b/src/http/v2/ngx_http_v2.h @@ -274,6 +274,8 @@ ngx_int_t ngx_http_v2_table_size(ngx_htt ngx_int_t ngx_http_v2_huff_decode(u_char *state, u_char *src, size_t len, u_char **dst, ngx_uint_t last, ngx_log_t *log); +size_t ngx_http_v2_huff_encode(u_char *src, size_t len, u_char *dst, + ngx_uint_t lower); #define ngx_http_v2_prefix(bits) ((1 << (bits)) - 1)