]> git.kaiwu.me - nginx.git/commitdiff
Avoid using QUIC connection after CONNECTION_CLOSE.
authorRoman Arutyunyan <arut@nginx.com>
Mon, 23 Mar 2020 16:19:44 +0000 (19:19 +0300)
committerRoman Arutyunyan <arut@nginx.com>
Mon, 23 Mar 2020 16:19:44 +0000 (19:19 +0300)
src/event/ngx_event_quic.c

index 4afa86bb090c3f2143b9fbcb260488711bc00af5..acc6e671abd48fb867f7cb398a00c08e57b9a502 100644 (file)
@@ -644,8 +644,8 @@ ngx_quic_input(ngx_connection_t *c, ngx_buf_t *b)
             rc = ngx_quic_app_input(c, &pkt);
         }
 
-        if (rc == NGX_ERROR) {
-            return NGX_ERROR;
+        if (rc != NGX_OK) {
+            return rc;
         }
 
         /* b->pos is at header end, adjust by actual packet length */
@@ -914,8 +914,7 @@ ngx_quic_payload_handler(ngx_connection_t *c, ngx_quic_header_t *pkt)
     }
 
     if (do_close) {
-        ngx_quic_close_connection(c);
-        return NGX_OK;
+        return NGX_DONE;
     }
 
     if (ack_this == 0) {