[PATCH] wininet: Use 64-bit size for contentLength.
Alexandre Julliard
julliard at winehq.org
Tue Aug 20 15:21:31 CDT 2019
Daniel Lehman <dlehman25 at gmail.com> writes:
> @@ -3724,9 +3724,17 @@ static DWORD HTTP_HttpQueryInfoW(http_request_t *request, DWORD dwInfoLevel,
> /* coalesce value to requested type */
> if (dwInfoLevel & HTTP_QUERY_FLAG_NUMBER && lpBuffer)
> {
> - *(int *)lpBuffer = atoiW(lphttpHdr->lpszValue);
> - TRACE(" returning number: %d\n", *(int *)lpBuffer);
> - }
> + if (*lpdwBufferLength == sizeof(ULONGLONG))
> + {
> + *(ULONGLONG *)lpBuffer = strtoulW(lphttpHdr->lpszValue, NULL, 10);
> + TRACE(" returning number: %s\n", wine_dbgstr_longlong(*(ULONGLONG *)lpBuffer));
strtoulW won't do what you want on 32-bit platforms.
--
Alexandre Julliard
julliard at winehq.org
More information about the wine-devel
mailing list