http://bugs.winehq.org/show_bug.cgi?id=8514
------- Additional Comments From citizenr@gmail.com 2007-28-05 05:47 ------- I glanced at your testcase ans saw that you only check the outcom of the getsockname call, if we want Wine to mimick Windows 100% that call even when returning WSAEINVAL should NOT zero the sockaddr structure, it should return it untouched like on windows (we all know there are people who code using windows bugs as feauteres). So i propose to add if (sa_set.sin_port == sa_get.sin_port) blabla