http://bugs.winehq.org/show_bug.cgi?id=32643
Bug #: 32643 Summary: getsockopt() does not indicate WSAEFAULT when setting optlen too small Product: Wine Version: 1.5.20 Platform: x86 OS/Version: Linux Status: UNCONFIRMED Severity: trivial Priority: P2 Component: winsock AssignedTo: wine-bugs@winehq.org ReportedBy: alexander255@lavabit.com Classification: Unclassified
Using the attached WSA code will cause an error on Windows but NOT on WINE. If you change "optlen" value to at least 4, the example the code will run smoothly on both platforms.