[PATCH] cygwin: make sys/socket.h completely visible from netinet/in.h

Corinna Vinschen corinna-cygwin@cygwin.com
Tue Jan 16 09:32:00 GMT 2018


On Jan 15 21:24, Yaakov Selkowitz wrote:
> While POSIX mandates that certain socket types shall be defined by the
> inclusing of <netinet/in.h>, it also says that this header may also make
> visible all <sys/socket.h> symbols.  Glibc does this, and without out it,
> some packages end up requiring an additional #include <sys/socket.h>.
> 
> Signed-off-by: Yaakov Selkowitz <yselkowi@redhat.com>
> ---
>  winsup/cygwin/include/cygwin/in.h  | 2 +-
>  winsup/cygwin/include/sys/socket.h | 1 -
>  2 files changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/winsup/cygwin/include/cygwin/in.h b/winsup/cygwin/include/cygwin/in.h
> index 9d7331d30..42b776653 100644
> --- a/winsup/cygwin/include/cygwin/in.h
> +++ b/winsup/cygwin/include/cygwin/in.h
> @@ -18,7 +18,7 @@
>  #ifndef _CYGWIN_IN_H
>  #define _CYGWIN_IN_H
>  
> -#include <cygwin/socket.h>
> +#include <sys/socket.h>
>  
>  #ifndef _IN_ADDR_T_DECLARED
>  typedef	__uint32_t	in_addr_t;
> diff --git a/winsup/cygwin/include/sys/socket.h b/winsup/cygwin/include/sys/socket.h
> index 9e897a9ff..e6b92eef8 100644
> --- a/winsup/cygwin/include/sys/socket.h
> +++ b/winsup/cygwin/include/sys/socket.h
> @@ -11,7 +11,6 @@ details. */
>  
>  #include <features.h>
>  #include <cygwin/socket.h>
> -#include <sys/time.h>

You don't explain the incentive behind removing sys/time.h.  Sure this
doesn't break anything?


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <http://cygwin.com/pipermail/cygwin-patches/attachments/20180116/20f4cf75/attachment.sig>


More information about the Cygwin-patches mailing list