[PATCH 4/5] ntdll: Error out when trying to use a UDP-only option on a TCP socket

Alex Henrie alexhenrie24 at gmail.com
Mon Aug 16 00:49:10 CDT 2021


On Sun, Aug 15, 2021 at 1:03 PM Zebediah Figura (she/her)
<zfigura at codeweavers.com> wrote:
>
> On 8/15/21 1:58 PM, Alex Henrie wrote:
> > On Fri, Aug 13, 2021 at 10:05 AM Zebediah Figura (she/her)
> > <zfigura at codeweavers.com> wrote:
> >>
> >> Do these options not return EINVAL on a known system? What do they
> >> return instead? At least the commit message, if not the code, should
> >> mention this.
> >
> > These protocol+option combinations result in WSAEINVAL on every
> > version of Windows from XP on; no need to mark any of them as BROKEN
> > in the tests.
>
> I mean on the host Unix system. If they already return EINVAL there's no
> need to handle them specially.

Linux supports every one of these options on UDP sockets.

Mac OS supports IP_PKTINFO, IPV6_PKTINFO, IPV6_HOPLIMIT, and
IPV6_RECVTCLASS on UDP.

However, Mac OS sets EOPNOTSUPP for IP_MULTICAST_IF, IP_MULTICAST_TTL,
IP_MULTICAST_LOOP, IPV6_MULTICAST_IF, IPV6_MULTICAST_HOPS, and
IPV6_MULTICAST_LOOP on UDP.

So, if we are to replicate the Windows behavior, the TCP/UDP check has
to happen in Wine. I'll add an explanatory note to the commit message.

-Alex



More information about the wine-devel mailing list