[PATCH 5/5] ws2_32/tests: Add tabular socket option validity tests
Zebediah Figura (she/her)
zfigura at codeweavers.com
Mon Aug 16 11:42:06 CDT 2021
This patch loses the tests for IP_ADD_MEMBERSHIP et al.
Also:
> + for (opt = 0; opt < 100; opt++)
I'm not a huge fan of this. It kind of works for IP options, but it
wouldn't work if we extended these tests to e.g. SOL_SOCKET. I'm also
not sure I see the value in exhaustively testing undocumented or invalid
sockopts. Maybe check one or two obviously invalid numbers just to show
what the invalid behaviour is (and of course put that in the table proper).
> + { IPV6_GET_IFLIST, WSAEINVAL, BROKEN /* win8 */ | TODO },
This still isn't clear enough to me; it looks like it means "broken on
windows 8", not "broken on anything before windows 8".
Also, what's the broken case anyway? If it's just a matter of some
versions not supporting the option yet and returning WSAENOPROTOOPT, is
it even worth putting it in the table? Can we just have a blanket "||
broken(ret == -1 && WSAGetLastError() == WSAENOPROTOOPT)"?
> + { 2, WSAEINVAL, TODO },
This is IPV6_HDRINCL.
> + { 47, WSAEINVAL, BROKEN /* vista */ | TODO },
IP_ORIGINAL_ARRIVAL_IF (yes, used with IPPROTO_IPV6; see [1].)
[1]
https://docs.microsoft.com/en-us/windows/win32/winsock/ipproto-ipv6-socket-options
More information about the wine-devel
mailing list