Mercurial > hg > octave-lyh > gnulib-hg
changeset 6328:e1100f1eda79
* getaddrinfo.h: Move sys/types.h include first, reported by "Mark
D. Baushke" <mdb@gnu.org>.
author | Simon Josefsson <simon@josefsson.org> |
---|---|
date | Tue, 04 Oct 2005 09:53:09 +0000 |
parents | 0bf4e78a4658 |
children | ffad934ef3bd |
files | lib/ChangeLog lib/getaddrinfo.h |
diffstat | 2 files changed, 12 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/lib/ChangeLog +++ b/lib/ChangeLog @@ -1,3 +1,8 @@ +2005-10-04 Simon Josefsson <jas@extundo.com> + + * getaddrinfo.h: Move sys/types.h include first, reported by "Mark + D. Baushke" <mdb@gnu.org>. + 2005-10-03 Paul Eggert <eggert@cs.ucla.edu> * getdelim.c: Include getdelim.h first. Include <limits.h>.
--- a/lib/getaddrinfo.h +++ b/lib/getaddrinfo.h @@ -20,6 +20,13 @@ # define GETADDRINFO_H /* Get all getaddrinfo related declarations, if available. */ +# ifdef HAVE_SYS_TYPES_H +/* sys/socket.h in i386-unknown-freebsd4.10 and + powerpc-apple-darwin5.5 require sys/types.h, so include it first. + Then we'll also get 'socklen_t' and 'struct sockaddr' which are + used below. */ +# include <sys/types.h> +# endif # ifdef HAVE_SYS_SOCKET_H # include <sys/socket.h> # endif @@ -29,12 +36,6 @@ # ifndef HAVE_STRUCT_ADDRINFO -/* Get 'socklen_t', and 'struct sockaddr' via sys/types.h which are - used below. */ -# ifdef HAVE_SYS_TYPES_H -# include <sys/types.h> -# endif - /* Structure to contain information about address of a service provider. */ struct addrinfo {