http://bugs.winehq.org/show_bug.cgi?id=35284
--- Comment #5 from Bruno Jesus 00cpxxx@gmail.com --- Removing or relaxing that check makes tests fail. The problem may be somewhere else, at first I thought WSADuplicateSocket could not be filling the WSAPROTOCOL_INFOW struct correctly (fields iMaxSockAddr,iMinSockAddr) but that was not the case.
AF can you please check if the value used to call the function is static or from a variable? And if it's from a variable does it come from a call to other winsock function?