comparison src/http/v2/ngx_http_v2_table.c @ 7107:d4b031cf32cf

HTTP/2: fixed debug log about indexed headers. Previously, "get indexed header" message was logged when in fact only header name was obtained using an index, and "get indexed header name" was logged when full header representation (name and value) was obtained using an index. Fixed version logs "get indexed name" and "get indexed header" respectively.
author Maxim Dounin <mdounin@mdounin.ru>
date Thu, 14 Sep 2017 19:06:05 +0300
parents 257b51c37c5a
children 2bf605c6edf7
comparison
equal deleted inserted replaced
7106:d77407baccd1 7107:d4b031cf32cf
100 return NGX_ERROR; 100 return NGX_ERROR;
101 } 101 }
102 102
103 ngx_log_debug2(NGX_LOG_DEBUG_HTTP, h2c->connection->log, 0, 103 ngx_log_debug2(NGX_LOG_DEBUG_HTTP, h2c->connection->log, 0,
104 "http2 get indexed %s: %ui", 104 "http2 get indexed %s: %ui",
105 name_only ? "header" : "header name", index); 105 name_only ? "name" : "header", index);
106 106
107 index--; 107 index--;
108 108
109 if (index < NGX_HTTP_V2_STATIC_TABLE_ENTRIES) { 109 if (index < NGX_HTTP_V2_STATIC_TABLE_ENTRIES) {
110 h2c->state.header = ngx_http_v2_static_table[index]; 110 h2c->state.header = ngx_http_v2_static_table[index];