Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@nberlee
Copy link
Contributor

@nberlee nberlee commented Nov 15, 2025

1. Why is this pull request needed and what does it do?

Fixes a reload crash in DNS-over-QUIC by lazily creating s.quicListener inside ServePacket when it’s nil, so the reused socket from reload no longer causes a panic.

2. Which issues (if any) are related?

fixes #7679

3. Which documentation changes (if any) need to be made?

None

4. Does this introduce a backward incompatible change or deprecation?

No

ServePacket on reload receives the reused PacketConn before the new
ServerQUIC has recreated its quic.Listener, so quicListener is nil and
the process panics. Lazily initialise quicListener from the provided
PacketConn when it’s nil and then proceed with ServeQUIC.

fixes: coredns#7679
Signed-off-by: Nico Berlee <[email protected]>
@yongtang
Copy link
Member

@nberlee Thanks for the PR! Wondering if it is possible to add a test case?

@nberlee
Copy link
Contributor Author

nberlee commented Nov 18, 2025

@yongtang i've added a test

Copy link
Collaborator

@thevilledev thevilledev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@yongtang
Copy link
Member

@yongtang i've added a test

@nberlee Thanks for the contribution!

@yongtang yongtang merged commit 7d7bbc8 into coredns:master Nov 18, 2025
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Reloading DNS-over-QUIC crashes: ServePacket dereferences nil quicListener

3 participants