]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
(res_querydomain): Avoid potential buffer overrun.
authorUlrich Drepper <drepper@redhat.com>
Sun, 21 Dec 1997 21:19:24 +0000 (21:19 +0000)
committerUlrich Drepper <drepper@redhat.com>
Sun, 21 Dec 1997 21:19:24 +0000 (21:19 +0000)
resolv/res_query.c

index 545e009e8dfe4493ce435b38da8d1db6bb328885..28ac3828c2e3d7bfe6d5e48ef3230aa464102cd0 100644 (file)
@@ -321,7 +321,7 @@ res_querydomain(name, domain, class, type, answer, anslen)
        u_char *answer;         /* buffer to put answer */
        int anslen;             /* size of answer */
 {
-       char nbuf[MAXDNAME];
+       char nbuf[MAXDNAME * 2 + 2];
        const char *longname = nbuf;
        int n;