[tor-bugs] #4533 [Tor Client]: compat.h: tor_socket_t defined as intptr_t instead native SOCKET (Windows)
Tor Bug Tracker & Wiki
torproject-admin at torproject.org
Fri Dec 2 21:42:38 UTC 2011
#4533: compat.h: tor_socket_t defined as intptr_t instead native SOCKET (Windows)
---------------------------+------------------------------------------------
Reporter: troll_un | Owner:
Type: defect | Status: new
Priority: major | Milestone: Tor: 0.2.3.x-final
Component: Tor Client | Version:
Resolution: | Keywords: Windows easy
Parent: | Points:
Actualpoints: |
---------------------------+------------------------------------------------
Comment(by nickm):
So the risky thing here is that SOCKET is defined as u_int on win32 and
UINT_PTR on win64. If we make this change, we will have tor_socket_t be
unsigned on windows and signed everywhere else. Every place that
currently checks for sockets being < 0 will instead have to use the
SOCKET_OK macro.
That said, I'm okay doing this on 0.2.3.x if we can seriously audit
everything that looks at a socket for correctness.
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/4533#comment:2>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
More information about the tor-bugs
mailing list