mirror of
https://github.com/nginx/nginx.git
synced 2024-11-27 23:49:00 +08:00
QUIC: removed unnecessary closing of active/backup sockets.
All open sockets are stored in a queue. There is no need to close some of them separately. If it happens that active and backup point to same socket, double close may happen (leading to possible segfault).
This commit is contained in:
parent
82b4912a8e
commit
0de6a1ebb4
@ -288,12 +288,6 @@ ngx_quic_close_sockets(ngx_connection_t *c)
|
||||
|
||||
qc = ngx_quic_get_connection(c);
|
||||
|
||||
ngx_quic_close_socket(c, qc->socket);
|
||||
|
||||
if (qc->backup) {
|
||||
ngx_quic_close_socket(c, qc->backup);
|
||||
}
|
||||
|
||||
while (!ngx_queue_empty(&qc->sockets)) {
|
||||
q = ngx_queue_head(&qc->sockets);
|
||||
qsock = ngx_queue_data(q, ngx_quic_socket_t, queue);
|
||||
|
Loading…
Reference in New Issue
Block a user