[Asterisk-code-review] dns core: Allow zero-length DNS responses. (asterisk[master])

Mark Michelson asteriskteam at digium.com
Wed Jul 29 15:00:14 CDT 2015


Mark Michelson has uploaded a new patch set (#2).

Change subject: dns_core: Allow zero-length DNS responses.
......................................................................

dns_core: Allow zero-length DNS responses.

A testsuite test recently failed due to a crash that occurred in the DNS
core. The problem was that the test could not resolve an address, did
not set a result on the DNS query, and then indicated the query was
completed. The DNS core does not handle the case of a query with no
result gracefully, and so there is a crash.

This changeset makes the DNS system resolver set a result with a
zero-length answer in the case that a DNS resolution failure occurs
early. The DNS core now also will accept such a response without
treating it as invalid input. A unit test was updated to no longer treat
setting a zero-length response as off-nominal.

Change-Id: Ie56641e22debdaa61459e1c9a042e23b78affbf6
---
M main/dns.c
M main/dns_core.c
M tests/test_dns.c
3 files changed, 3 insertions(+), 11 deletions(-)


  git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/85/985/2
-- 
To view, visit https://gerrit.asterisk.org/985
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ie56641e22debdaa61459e1c9a042e23b78affbf6
Gerrit-PatchSet: 2
Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-Owner: Mark Michelson <mmichelson at digium.com>
Gerrit-Reviewer: Richard Mudgett <rmudgett at digium.com>



More information about the asterisk-code-review mailing list