[PATCH v2 5/6] winhttp: Don't send pong on timeout in socket_receive().

Hans Leidekker hans at codeweavers.com
Wed Jan 26 08:26:57 CST 2022


On Wed, 2022-01-26 at 16:14 +0300, Paul Gofman wrote:
> Signed-off-by: Paul Gofman <pgofman at codeweavers.com>
> ---
>      v2:
>           - no changes.
> 
>      As testing involves waiting for timeouts it doesn't look good for inclusion into the test suite.
>      I've tested this change separately: https://gist.github.com/gofman/bd2f3b6fd6cbe993e97353560ce81e04
>      This test succeeds on Windows for me but fails without this patch in Wine: the server close status received 
>      during closing handshake becomes WINHTTP_WEB_SOCKET_PROTOCOL_ERROR_CLOSE_STATUS (1002).
> 
>      Sending ping instead of pong causes the server to send a pong reply as expected although I still see status
>      1002 on close after. Which probably suggests that Windows doesn't send the ping as well (I also tried that with
>      WINHTTP_OPTION_WEB_SOCKET_KEEPALIVE_INTERVAL socket option set to 15000 and Sleep to 30000).

It should be an unsollicited pong, which serves as a keepalive packet. I'm
pretty sure I observed this, although I don't remember the exact conditions.






More information about the wine-devel mailing list