On 2013.03.04 14:38, Toby Gray wrote: > Why winsock.h and not winsock2.h?
Simple. I tried winsock2 and got plenty of conflicts. And since I didn't have time to invest resolving them, I went with winsock. > Does the WDK only include winsock.h? Last time I checked, I think all the Windows platforms we support have both. > As far as I understand it, winsock2 seems to have been in Windows 98 and > beyond. Yeah. The problem is it doesn't play along well with windows.h, that includes winsock. > This is going to be a bit annoying for us as we already use winsock2.h > in some files which also include libusb.h. However I believe the fix is > to just #include <winsock2.h> before we #include <libusb.h> it shouldn't > be too bad. Well, my current understanding is that anybody who uses libusb and wants to use winsock2.h has to take some action, due to libusb.h inluding windows.h including winsock.h. On the other hand, if you want to take a look at the issue, and can figure out a good way to include winsock2.h, I'll take a patch... ;) I've been a reluctant to try to include winsock2.h before windows.h, as per the advocated "solution" [1], on account that it's so friggin' inelegant that it'll make me want to throw a pie in the face of the next Microsoft employee I see. I fail to believe that their wasn't a better way for MS to solve the sock vs sock2 conflicts. But if you or others think that going for winsock2.h include first is what we should do, I guess I'll go for that (and start stocking up on pies...). > Can we have a release note saying as much so that people who upgrade and > see this issue can easily workout how to fix it? Again, with winsock.h being included from windows.h by default, I don't think us adding the extra winsock.h include should matter much to current users. But sure, we can add a note. Regards, [1] http://social.msdn.microsoft.com/Forums/en-US/windowssdk/thread/4a90b143-1fb8-43e9-a54c-956127e0c579 ------------------------------------------------------------------------------ Everyone hates slow websites. So do we. Make your web apps faster with AppDynamics Download AppDynamics Lite for free today: http://p.sf.net/sfu/appdyn_d2d_feb _______________________________________________ libusbx-devel mailing list libusbx-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/libusbx-devel