[PATCH] getaddrinfo: Treat empty string as NULL

Ulrich Drepper drepper@redhat.com
Fri Sep 21 17:33:00 GMT 2007


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Simon Perreault wrote:
> Shouldn't the empty string be treated as NULL, as is "*"?
> (For the name and service parameters.)

No, I don't think this is correct.  The "*" handling shouldn't even be
there.  The only reason is historic practice and compatibility.  "" is
just an invalid valid and people should correct their code.

- --
➧ Ulrich Drepper ➧ Red Hat, Inc. ➧ 444 Castro St ➧ Mountain View, CA ❖
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (GNU/Linux)

iD8DBQFG9AA+2ijCOnn/RHQRAr0JAKC5yvRH131UMPMoo8wy0Pj8ujy6VQCgnrww
+0o47OuNwKuCdDyc/75G2VM=
=sJk5
-----END PGP SIGNATURE-----



More information about the Libc-alpha mailing list