mirror of
https://github.com/ApfelTeeSaft/reactos.git
synced 2026-08-26 19:33:31 +00:00
[DHCPCSVC] Improve debug message and parameter checks for DhcpRequestParams
This commit is contained in:
@@ -669,9 +669,14 @@ DhcpRequestParams(
|
||||
{
|
||||
DWORD ret = ERROR_SUCCESS;
|
||||
|
||||
DPRINT1("DhcpRequestParams(%lx %p %S %p %p %p %p %p %S)\n",
|
||||
Flags, Reserved, AdapterName, ClassId, SendParams,
|
||||
RecdParams, Buffer, pSize, RequestIdStr);
|
||||
DPRINT1("DhcpRequestParams(%lx %p %S %p %lu %p %lu %p %p %p %S)\n",
|
||||
Flags, Reserved, AdapterName, ClassId, SendParams.nParams, SendParams.Params,
|
||||
RecdParams.nParams, RecdParams.Params, Buffer, pSize, RequestIdStr);
|
||||
|
||||
if ((Flags != DHCPCAPI_REQUEST_SYNCHRONOUS) &&
|
||||
(Flags != DHCPCAPI_REQUEST_PERSISTENT) &&
|
||||
(Flags != (DHCPCAPI_REQUEST_SYNCHRONOUS | DHCPCAPI_REQUEST_PERSISTENT)))
|
||||
return ERROR_INVALID_PARAMETER;
|
||||
|
||||
if ((Reserved != NULL) || (AdapterName == NULL))
|
||||
return ERROR_INVALID_PARAMETER;
|
||||
@@ -685,6 +690,12 @@ DhcpRequestParams(
|
||||
return ERROR_INVALID_PARAMETER;
|
||||
}
|
||||
|
||||
if ((SendParams.nParams != 0) && (SendParams.Params == NULL))
|
||||
return ERROR_INVALID_PARAMETER;
|
||||
|
||||
if (RecdParams.Params == NULL)
|
||||
return ERROR_INVALID_PARAMETER;
|
||||
|
||||
RpcTryExcept
|
||||
{
|
||||
ret = Client_RequestParams(NULL,
|
||||
|
||||
Reference in New Issue
Block a user