summaryrefslogtreecommitdiffhomepage
path: root/src/nxt_h1proto.c
diff options
context:
space:
mode:
authorValentin Bartenev <vbart@nginx.com>2018-01-15 20:50:14 +0300
committerValentin Bartenev <vbart@nginx.com>2018-01-15 20:50:14 +0300
commita073616fc35b76fce4c4cc1b3ad30837a22d5499 (patch)
tree78b91d5c19a2300ee4fd0a8b1f1cf40649f7071d /src/nxt_h1proto.c
parent3fb140d6d2f8bf0344e7c311923178db808cb437 (diff)
downloadunit-a073616fc35b76fce4c4cc1b3ad30837a22d5499.tar.gz
unit-a073616fc35b76fce4c4cc1b3ad30837a22d5499.tar.bz2
Improved HTTP version representation.
Diffstat (limited to 'src/nxt_h1proto.c')
-rw-r--r--src/nxt_h1proto.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nxt_h1proto.c b/src/nxt_h1proto.c
index 5623c019..ac60753d 100644
--- a/src/nxt_h1proto.c
+++ b/src/nxt_h1proto.c
@@ -254,7 +254,7 @@ nxt_h1p_header_parse(nxt_task_t *task, void *obj, void *data)
* enabled in HTTP/1.1. The mode can be overridden later by
* the "Connection" field processed in nxt_h1p_connection().
*/
- h1p->keepalive = (h1p->parser.version.str[7] != '0');
+ h1p->keepalive = (h1p->parser.version.s.minor != '0');
r->fields = h1p->parser.fields;
@@ -658,7 +658,7 @@ nxt_h1p_request_header_send(nxt_task_t *task, nxt_http_request_t *r)
/* Trailing CRLF at the end of header. */
size += sizeof("\r\n") - 1;
- http11 = (h1p->parser.version.str[7] != '0');
+ http11 = (h1p->parser.version.s.minor != '0');
if (r->resp.content_length == NULL || r->resp.content_length->skip) {
if (http11) {