summaryrefslogtreecommitdiffabout
path: root/src/dnsbase.c
Side-by-side diff
Diffstat (limited to 'src/dnsbase.c') (more/less context) (ignore whitespace changes)
-rw-r--r--src/dnsbase.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/dnsbase.c b/src/dnsbase.c
index 3d06316..ba5de17 100644
--- a/src/dnsbase.c
+++ b/src/dnsbase.c
@@ -576,8 +576,9 @@ dns_resolve_hostname(const char *host, char *answer, size_t answer_size,
{
struct loop_data ld;
char namebuf[NSIZE];
- char domainbuf[NSIZE] = "";
-
+ char domainbuf[NSIZE];
+
+ domainbuf[0] = 0;
ld.qtype = ld.atype = T_A;
strncpy(namebuf, host, sizeof namebuf - 1);
@@ -616,8 +617,9 @@ a_lookup(const char *host,
{
struct loop_data ld;
char namebuf[NSIZE];
- char domainbuf[NSIZE] = "";
+ char domainbuf[NSIZE];
+ domainbuf[0] = 0;
ld.qtype = ld.atype = T_A;
strncpy(namebuf, host, sizeof namebuf - 1);
ld.name = namebuf;

Return to:

Send suggestions and report system problems to the System administrator.