[tor-bugs] #5861 [Tor Relay]: MSVC/win32: IPPROTO_IPV6 only defined when _WIN32_WINNT >= 0x0501

Tor Bug Tracker & Wiki torproject-admin at torproject.org
Mon May 14 17:21:10 UTC 2012


#5861: MSVC/win32: IPPROTO_IPV6 only defined when _WIN32_WINNT >= 0x0501
--------------------------+-------------------------------------------------
 Reporter:  nickm         |          Owner:                    
     Type:  defect        |         Status:  new               
 Priority:  major         |      Milestone:  Tor: 0.2.3.x-final
Component:  Tor Relay     |        Version:                    
 Keywords:  windows msvc  |         Parent:                    
   Points:                |   Actualpoints:                    
--------------------------+-------------------------------------------------
 When we're providing IPv6 support, we need to setsockopt(IPPROTO_IPV6,
 IPPROTO_IPV6ONLY) on our listeners so that they bind the address we want
 them to bind.

 But with the MS-provided ws2def.h I've got, IPPROTO_IPV6 is only declared
 when _WIN32_WINNT >= 0x0501 (that is, when we say we want to build for XP
 or higher).

 The easiest fix here would be to just drop support for pre-XP windowses
 and set _WIN32_WINNT to 0x0501.  The next-easiest fix would be to hard-
 define IPPROTO_IPV6 to 41 when building for windows.

 Marking this as "major" because it blocks building with MSVC.

-- 
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/5861>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list