[PATCH] Workarounds for lotro bugs

Rob Shearman robertshearman at gmail.com
Wed Jul 16 07:45:09 CDT 2008

2008/7/16 Daniel Santos <daniel at bytesage.com>:
> +    if(_lotro_hack_enabled
> +            && to->sa_family == AF_INET
> +            && dwBufferCount == 1
> +            && _lotro_hack(&get_per_thread_data()->lotro_msgs,
> +                    s, lpBuffers, (struct WS_sockaddr_in*)to)) {
> +        Sleep(10);
> +        if(lpNumberOfBytesSent) {
> +            *lpNumberOfBytesSent = lpBuffers->len;
> +        }
> +        return 0;
> +    }
> +

Hi Daniel,

While I appreciate the effort you've gone to to fix a bug, I don't see
any analysis in the bug that suggests this is the only possible
solution. It seems to me as though LOTRO is calling WSASendTo in a
tight loop and that it isn't such a tight loop on Windows. A +relay
log will reveal which calls it is making in that thread. You can then
build a similar test program and time how long each call takes on
Windows and Wine and see where the difference is (although it probably
won't be as simple as that as there will be other threads interacting
in LOTRO). At a guess, it might simply be that Windows yields to other
threads after making a call to a network function.

Rob Shearman

More information about the wine-devel mailing list