Andreas Schwab
44414488d6
- Import patches from 2.23 branch OBS-URL: https://build.opensuse.org/request/show/394998 OBS-URL: https://build.opensuse.org/package/show/Base:System/glibc?expand=0&rev=436
25 lines
636 B
Diff
25 lines
636 B
Diff
2016-04-11 Florian Weimer <fweimer@redhat.com>
|
|
|
|
[BZ #19865]
|
|
* resolv/nss_dns/dns-canon.c (_nss_dns_getcanonname_r): Restore
|
|
original buffer before retry.
|
|
|
|
Index: glibc-2.23/resolv/nss_dns/dns-canon.c
|
|
===================================================================
|
|
--- glibc-2.23.orig/resolv/nss_dns/dns-canon.c
|
|
+++ glibc-2.23/resolv/nss_dns/dns-canon.c
|
|
@@ -144,6 +144,13 @@ _nss_dns_getcanonname_r (const char *nam
|
|
ptr += sizeof (uint16_t) + __ns_get16 (ptr);
|
|
}
|
|
}
|
|
+
|
|
+ /* Restore original buffer before retry. */
|
|
+ if (ansp.ptr != buf)
|
|
+ {
|
|
+ free (ansp.ptr);
|
|
+ ansp.ptr = buf;
|
|
+ }
|
|
}
|
|
|
|
out:
|