From: Bruno Haible Date: Tue, 30 Jun 2020 00:26:45 +0000 (+0200) Subject: sys_socket: Don't define socklen_t if it is already defined on mingw. X-Git-Tag: v1.0~3944 X-Git-Url: https://gitweb.git.savannah.gnu.org/gitweb/?a=commitdiff_plain;h=4e3f2d4cfdba14e1d89479362061a9280f2f22b6;p=gnulib.git sys_socket: Don't define socklen_t if it is already defined on mingw. Reported by Keith Marshall in , by Rahul Das in , and by Eli Zaretskii in . * lib/sys_socket.in.h (socklen_t): Remove definition. --- diff --git a/ChangeLog b/ChangeLog index e0b5ace41b..9005fa3338 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,14 @@ +2020-06-29 Bruno Haible + + sys_socket: Don't define socklen_t if it is already defined on mingw. + Reported by Keith Marshall in + , + by Rahul Das in + , + and by Eli Zaretskii in + . + * lib/sys_socket.in.h (socklen_t): Remove definition. + 2020-06-29 Bruno Haible alloca-opt: Fix warning on mingw. diff --git a/lib/sys_socket.in.h b/lib/sys_socket.in.h index 948d689a89..577947dc88 100644 --- a/lib/sys_socket.in.h +++ b/lib/sys_socket.in.h @@ -195,12 +195,7 @@ struct sockaddr_storage /* Include headers needed by the emulation code. */ # include # include - -# if !GNULIB_defined_socklen_t -typedef int socklen_t; -# define GNULIB_defined_socklen_t 1 -# endif - +/* If these headers don't define socklen_t, does. */ # endif /* Rudimentary 'struct msghdr'; this works as long as you don't try to