Commit 954bf9e0 authored by Billy Laws's avatar Billy Laws Committed by Alexandre Julliard

ntdll: Avoid using SOL_IPX to detect whether IPX is supported.

4.18+ Linux kernels remove support for IPX but keep SOL_IPX defined, which causes compilation errors as wine unconditionally uses IPX structures if this is the case. Instead check for IPX_MTU to determine IPX support as it is defined within the ipx.h header itself.
parent a0534afa
...@@ -45,6 +45,7 @@ ...@@ -45,6 +45,7 @@
#ifdef HAVE_NETIPX_IPX_H #ifdef HAVE_NETIPX_IPX_H
# include <netipx/ipx.h> # include <netipx/ipx.h>
# define HAS_IPX
#elif defined(HAVE_LINUX_IPX_H) #elif defined(HAVE_LINUX_IPX_H)
# ifdef HAVE_ASM_TYPES_H # ifdef HAVE_ASM_TYPES_H
# include <asm/types.h> # include <asm/types.h>
...@@ -53,8 +54,6 @@ ...@@ -53,8 +54,6 @@
# include <linux/types.h> # include <linux/types.h>
# endif # endif
# include <linux/ipx.h> # include <linux/ipx.h>
#endif
#if defined(SOL_IPX) || defined(SO_DEFAULT_HEADERS)
# define HAS_IPX # define HAS_IPX
#endif #endif
...@@ -2406,6 +2405,7 @@ NTSTATUS sock_ioctl( HANDLE handle, HANDLE event, PIO_APC_ROUTINE apc, void *apc ...@@ -2406,6 +2405,7 @@ NTSTATUS sock_ioctl( HANDLE handle, HANDLE event, PIO_APC_ROUTINE apc, void *apc
break; break;
} }
#ifdef HAS_IPX
#ifdef SOL_IPX #ifdef SOL_IPX
case IOCTL_AFD_WINE_GET_IPX_PTYPE: case IOCTL_AFD_WINE_GET_IPX_PTYPE:
return do_getsockopt( handle, io, SOL_IPX, IPX_TYPE, out_buffer, out_size ); return do_getsockopt( handle, io, SOL_IPX, IPX_TYPE, out_buffer, out_size );
...@@ -2444,6 +2444,7 @@ NTSTATUS sock_ioctl( HANDLE handle, HANDLE event, PIO_APC_ROUTINE apc, void *apc ...@@ -2444,6 +2444,7 @@ NTSTATUS sock_ioctl( HANDLE handle, HANDLE event, PIO_APC_ROUTINE apc, void *apc
return do_setsockopt( handle, io, 0, SO_DEFAULT_HEADERS, &value, sizeof(value) ); return do_setsockopt( handle, io, 0, SO_DEFAULT_HEADERS, &value, sizeof(value) );
} }
#endif #endif
#endif
#ifdef HAS_IRDA #ifdef HAS_IRDA
#define MAX_IRDA_DEVICES 10 #define MAX_IRDA_DEVICES 10
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment