diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2014-04-16 08:58:20 +0000 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2014-04-16 08:58:20 +0000 |
commit | c0efb4de1c53f16b9af12584a921d00a3af23cfd (patch) | |
tree | 6e43c4ad94d4434936e9ec47a469bcb1ea2173de /winsup/cygwin/net.cc | |
parent | b5a7cb02cd9d4050d5985a355c9931eae55246bb (diff) | |
download | cygnal-c0efb4de1c53f16b9af12584a921d00a3af23cfd.tar.gz cygnal-c0efb4de1c53f16b9af12584a921d00a3af23cfd.tar.bz2 cygnal-c0efb4de1c53f16b9af12584a921d00a3af23cfd.zip |
* net.cc (cygwin_setsockopt): Ignore IPV6_TCLASS the same way as IP_TOS.
Diffstat (limited to 'winsup/cygwin/net.cc')
-rw-r--r-- | winsup/cygwin/net.cc | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/winsup/cygwin/net.cc b/winsup/cygwin/net.cc index 480570033..0e7776029 100644 --- a/winsup/cygwin/net.cc +++ b/winsup/cygwin/net.cc @@ -848,13 +848,22 @@ cygwin_setsockopt (int fd, int level, int optname, const void *optval, Sidenote: The reasoning for dropping ToS in Win2K is that ToS per RFC 1349 is incompatible with DiffServ per RFC 2474/2475. - We just ignore the return value of setting IP_TOS entirely. */ + We just ignore the return value of setting IP_TOS entirely. + + CV 2014-04-16: Same for IPV6_TCLASS + FIXME: Same for IPV6_RECVTCLASS? */ if (level == IPPROTO_IP && optname == IP_TOS && WSAGetLastError () == WSAEINVAL) { debug_printf ("Faked IP_TOS success"); res = 0; } + else if (level == IPPROTO_IPV6 && optname == IPV6_TCLASS + && WSAGetLastError () == WSAENOPROTOOPT) + { + debug_printf ("Faked IPV6_TCLASS success"); + res = 0; + } else set_winsock_errno (); } |