]> git.ipfire.org Git - thirdparty/knot-dns.git/commitdiff
QUIC/requestor: fix crash when counterpart closes connection
authorLibor Peltan <libor.peltan@nic.cz>
Sun, 4 Jan 2026 14:30:12 +0000 (15:30 +0100)
committerDaniel Salzman <daniel.salzman@nic.cz>
Sun, 4 Jan 2026 14:38:12 +0000 (15:38 +0100)
src/knot/query/quic-requestor.c

index cfeec479541a4931dfdf6b667dc3e05dc0e6b9f1..7d64d58842daeb7644cbb7032959f795b0b9a538 100644 (file)
@@ -255,6 +255,9 @@ int knot_qreq_recv(struct knot_quic_reply *r, struct iovec *out, int timeout_ms)
                if (ret != KNOT_EOK) {
                        return ret;
                }
+               if (conn->conn == NULL) {
+                       return KNOT_ECONN;
+               }
        }
 
        knot_tcp_inbufs_upd_res_t *firstib = stream->inbufs;