diff options
author | mmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-04-01 17:21:21 +0000 |
---|---|---|
committer | mmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-04-01 17:21:21 +0000 |
commit | a3039a9bd607e515c3cfc68db9d9f9dd6e2dab6a (patch) | |
tree | 76e3a6107a67c2e21bc5f412af8bccfe4e255505 /main/dns.c | |
parent | 1e2dfec8f61c985cc9c393a947232cc75e2e6693 (diff) |
Initialize the __res_state structure used for dns purposes
to all 0's prior to using it. This is due to valgrind's complaints
on issue #12284 as well as an excerpt found in "Description" portion
of the online man page found here:
http://www.iti.cs.tu-bs.de/cgi-bin/UNIXhelp/man-cgi?res_nquery+3RESOLV
(pertains to issue #12284 but does not necessarily close it)
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@112138 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'main/dns.c')
-rw-r--r-- | main/dns.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/main/dns.c b/main/dns.c index 2e17f6dd3..d57e6227a 100644 --- a/main/dns.c +++ b/main/dns.c @@ -255,6 +255,7 @@ int ast_search_dns(void *context, int res, ret = -1; #ifdef HAVE_RES_NINIT + memset(&dnsstate, 0, sizeof(dnsstate)); res_ninit(&dnsstate); res = res_nsearch(&dnsstate, dname, class, type, answer, sizeof(answer)); #else |