Mercurial > hg > nginx
comparison src/http/v3/ngx_http_v3_streams.c @ 8228:ac41c53e446d quic
Fixed HTTP/3 server stream creation.
author | Roman Arutyunyan <arut@nginx.com> |
---|---|
date | Wed, 18 Mar 2020 14:10:44 +0300 |
parents | 268f4389130d |
children | 618a65de08b3 |
comparison
equal
deleted
inserted
replaced
8227:36af1dab65e5 | 8228:ac41c53e446d |
---|---|
319 size_t n; | 319 size_t n; |
320 ngx_connection_t *sc; | 320 ngx_connection_t *sc; |
321 ngx_pool_cleanup_t *cln; | 321 ngx_pool_cleanup_t *cln; |
322 ngx_http_v3_uni_stream_t *us; | 322 ngx_http_v3_uni_stream_t *us; |
323 | 323 |
324 sc = ngx_quic_create_uni_stream(c->qs->parent); | 324 sc = ngx_quic_create_uni_stream(c); |
325 if (sc == NULL) { | 325 if (sc == NULL) { |
326 return NULL; | 326 return NULL; |
327 } | 327 } |
328 | 328 |
329 ngx_log_debug1(NGX_LOG_DEBUG_HTTP, c->log, 0, | 329 ngx_log_debug1(NGX_LOG_DEBUG_HTTP, c->log, 0, |
367 { | 367 { |
368 ngx_http_v3_connection_t *h3c; | 368 ngx_http_v3_connection_t *h3c; |
369 | 369 |
370 h3c = c->qs->parent->data; | 370 h3c = c->qs->parent->data; |
371 | 371 |
372 if (h3c->server_encoder == NULL) { | 372 if (h3c->server_control == NULL) { |
373 h3c->server_encoder = ngx_http_v3_create_uni_stream(c, | 373 h3c->server_control = ngx_http_v3_create_uni_stream(c, |
374 NGX_HTTP_V3_STREAM_CONTROL); | 374 NGX_HTTP_V3_STREAM_CONTROL); |
375 } | 375 } |
376 | 376 |
377 return h3c->server_encoder; | 377 return h3c->server_encoder; |
378 } | 378 } |
399 { | 399 { |
400 ngx_http_v3_connection_t *h3c; | 400 ngx_http_v3_connection_t *h3c; |
401 | 401 |
402 h3c = c->qs->parent->data; | 402 h3c = c->qs->parent->data; |
403 | 403 |
404 if (h3c->server_encoder == NULL) { | 404 if (h3c->server_decoder == NULL) { |
405 h3c->server_encoder = ngx_http_v3_create_uni_stream(c, | 405 h3c->server_decoder = ngx_http_v3_create_uni_stream(c, |
406 NGX_HTTP_V3_STREAM_DECODER); | 406 NGX_HTTP_V3_STREAM_DECODER); |
407 } | 407 } |
408 | 408 |
409 return h3c->server_encoder; | 409 return h3c->server_encoder; |
410 } | 410 } |