mirror of
https://sourceware.org/git/glibc.git
synced 2025-12-24 17:51:17 +03:00
Update.
* resolv/gethnamaddr.c: Account bytes needed for alignment in buflen. Patch by Olaf Kibrch <okir@lst.de>.
This commit is contained in:
@@ -420,6 +420,10 @@ getanswer(answer, anslen, qname, qtype)
|
||||
buflen -= nn;
|
||||
}
|
||||
|
||||
/* XXX: when incrementing bp, we have to decrement
|
||||
* buflen by the same amount --okir */
|
||||
buflen -= sizeof(align) - ((u_long)bp % sizeof(align));
|
||||
|
||||
bp += sizeof(align) - ((u_long)bp % sizeof(align));
|
||||
|
||||
if (bp + n >= &hostbuf[sizeof hostbuf]) {
|
||||
|
||||
Reference in New Issue
Block a user