httpapi: Allow passing NULL size to HttpReceiveHttpRequest().

Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=53980
This commit is contained in:
Zebediah Figura 2022-12-20 00:57:18 -06:00 committed by Alexandre Julliard
parent f5a81ff02a
commit d1d37e40d2

View file

@ -323,6 +323,7 @@ ULONG WINAPI HttpReceiveHttpRequest(HANDLE queue, HTTP_REQUEST_ID id, ULONG flag
.bits = sizeof(void *) * 8,
};
ULONG ret = ERROR_SUCCESS;
ULONG local_ret_size;
OVERLAPPED sync_ovl;
TRACE("queue %p, id %s, flags %#lx, request %p, size %#lx, ret_size %p, ovl %p.\n",
@ -340,6 +341,9 @@ ULONG WINAPI HttpReceiveHttpRequest(HANDLE queue, HTTP_REQUEST_ID id, ULONG flag
ovl = &sync_ovl;
}
if (!ret_size)
ret_size = &local_ret_size;
if (!DeviceIoControl(queue, IOCTL_HTTP_RECEIVE_REQUEST, &params, sizeof(params), request, size, ret_size, ovl))
ret = GetLastError();