diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/dns.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/dns.cpp b/src/dns.cpp index f9411234d..123901f8a 100644 --- a/src/dns.cpp +++ b/src/dns.cpp @@ -665,7 +665,8 @@ char* DNS::dns_getresult_s(const int cfd, char *res) { /* retrieve result of DNS alist->next = NULL; break; } - goto defaultcase; + memcpy(res,&h.payload[i],rr.rdlength); + res[rr.rdlength] = '\0'; break; default: defaultcase: |