This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug nss/20612] getaddrinfo() returns EAI_SYSTEM depending on uninitialized value
- From: "fweimer at redhat dot com" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sourceware dot org
- Date: Fri, 16 Sep 2016 12:33:47 +0000
- Subject: [Bug nss/20612] getaddrinfo() returns EAI_SYSTEM depending on uninitialized value
- Auto-submitted: auto-generated
- References: <bug-20612-131@http.sourceware.org/bugzilla/>
https://sourceware.org/bugzilla/show_bug.cgi?id=20612
--- Comment #2 from Florian Weimer <fweimer at redhat dot com> ---
(In reply to Martin Panter from comment #1)
> enum nss_status _nss_wtf_gethostbyname2_r(const char *name, int af,
> struct hostent *he, char *buffer, size_t buflen, int *h_errnop) {
That function definition is incorrect, it should be:
enum nss_status
_nss_wtf_gethostbyname2_r (const char *name, int af, struct hostent *host,
char *buffer, size_t buflen, int *errnop,
int *h_errnop)
In effect, you are never updating *h_errnop (only *errnop), so the valgrind
warning is appropriate here.
--
You are receiving this mail because:
You are on the CC list for the bug.