[2/2] ws2_32: Implement returning the proper time with SO_CONNECT_TIME.

Sebastian Lackner sebastian at fds-team.de
Thu Nov 20 08:40:26 CST 2014


On 20.11.2014 15:30, Bruno Jesus wrote:
> 
> The bug is still there despite of the game code and that will also fix
> the test failures in BSD and Solaris where the SNDBUF and RECVBUF
> options are only hints to the kernel which usually ignores them
> completetly.
> 

Isn't it the same on Windows? Quote from MSDN:

--- snip ---
SO_RCVBUF and SO_SNDBUF
When a Windows Sockets implementation supports the SO_RCVBUF and SO_SNDBUF options, an application can request different buffer sizes (larger or smaller). ->The call to setsockopt can succeed even when the implementation did not provide the whole amount requested.<- An application must call getsockopt with the same option to check the buffer size actually provided.
--- snip ---

Seems like windows also doesn't give any guarantee that the value is used exactly as provided. Of course you can argue that some apps still might depend on that, but for me it sounds like at least the linux factor of 2 could be easily "solved" directly in usermode, without having new wineserver calls. Not sure about BSD or Salaris though.


On 20.11.2014 15:32, Bruno Jesus wrote:
> That's why storing the value in the server and using
> min(memory_stored_value, getsockopt_value) would solve this issue.
> Dividing by 2 would require the introduction of #ifdef.
> 

Setting a too small value would probably also get ignored or fail on Windows, so thats also not completely correct.




More information about the wine-devel mailing list