30b7d7995e
The type of fd_mask was changed in Cygwin 2.4.0 headers from 'long' to 'unsigned long'. This exposes an existing problem with winauth.c, which includes Xwindows.h (which includes windows.h, which defines WIN32), before including osdep.h, which causes the now conflicting definition of fd_mask in osdep.h to be exposed: In file included from ../os/osdep.h:198:18: error: conflicting types for ‘fd_mask’ typedef long int fd_mask; /usr/include/sys/select.h:46:23: note: previous declaration of ‘fd_mask’ was here typedef unsigned long fd_mask; Adjust the include guards in osdep.h to make sure we only use WIN32 guarded code when not compiling for Cygwin (i.e. WIN32 && !__CYGWIN__) This isn't a very elegant, but unfortunately appears to be the best solution, since it doesn't seem to be possible to write the test in a positive form. Future work: Should also audit of all the other uses of WIN32 in xserver, and make sure they are correct. Reviewed-by: Adam Jackson <ajax@redhat.com> Signed-off-by: Jon Turney <jon.turney@dronecode.org.uk> |
||
---|---|---|
.. | ||
.gitignore | ||
access.c | ||
auth.c | ||
backtrace.c | ||
busfault.c | ||
client.c | ||
connection.c | ||
io.c | ||
log.c | ||
Makefile.am | ||
mitauth.c | ||
oscolor.c | ||
osdep.h | ||
osinit.c | ||
reallocarray.c | ||
rpcauth.c | ||
strcasecmp.c | ||
strcasestr.c | ||
strlcat.c | ||
strlcpy.c | ||
strndup.c | ||
utils.c | ||
WaitFor.c | ||
xdmauth.c | ||
xdmcp.c | ||
xprintf.c | ||
xsha1.c | ||
xstrans.c |