This PR adds a commit submitted to the dnsmasq-discuss mailing list. It has been verified by users to prevent use-after-free bugs possibly even resulting in a crash when names for meanwhile expired DHCP leases are queried via DNS PTR.
In case this patch is not accepted 1:1 for dnsmasq upstream, we can easily revert this PR later.
Related issue or feature (if applicable): N/A
Pull request in docs with documentation (if applicable): N/A
By submitting this pull request, I confirm the following:
I have read and understood the contributors guide, as well as this entire template. I understand which branch to base my commits and Pull Requests against.
I have commented my proposed changes within the code.
I am willing to help maintain this change if there are issues with it later.
What does this implement/fix?
This PR adds a commit submitted to the
dnsmasq-discuss
mailing list. It has been verified by users to prevent use-after-free bugs possibly even resulting in a crash when names for meanwhile expired DHCP leases are queried via DNS PTR.In case this patch is not accepted 1:1 for
dnsmasq
upstream, we can easily revert this PR later.Related issue or feature (if applicable): N/A
Pull request in docs with documentation (if applicable): N/A
By submitting this pull request, I confirm the following:
git rebase
)Checklist:
developmental
branch.