Jon Griffiths <[EMAIL PROTECTED]> writes:

> +            while (send_len)
> +            {
> +                wsabuf.len = send_len;
> +                if (wsabuf.len > chunk_len)
> +                    wsabuf.len = chunk_len;
> +                if (!ReadFile(packet->u.s.hFile, wsabuf.buf, wsabuf.len, &n, 
> NULL))
> +                    goto TransmitPackets_fail;
> +                wsabuf.len = n;
> +                if (WSASendTo(s, &wsabuf, 1, &n, 0, NULL, 0, NULL, NULL) == 
> SOCKET_ERROR)
> +                    goto TransmitPackets_fail;
> +                send_len -= n;
> +            }

This is still wrong, WSASendTo doesn't necessarily send the whole
buffer.

-- 
Alexandre Julliard
[EMAIL PROTECTED]


Reply via email to