mirror of
https://github.com/reactos/reactos.git
synced 2025-05-19 00:54:18 +00:00
[NDIS]
- Fix some sickening formatting disasters - Allocate the unicode string buffers from paged pool, like everything else in the NDIS config API svn path=/trunk/; revision=56590
This commit is contained in:
parent
e416c79745
commit
edfbcd133b
1 changed files with 9 additions and 15 deletions
|
@ -444,10 +444,8 @@ NdisReadConfiguration(
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(
|
if(!wcsncmp(Keyword->Buffer, L"Environment", Keyword->Length/sizeof(WCHAR)) &&
|
||||||
!wcsncmp(Keyword->Buffer, L"Environment", Keyword->Length/sizeof(WCHAR)) &&
|
wcslen(L"Environment") == Keyword->Length/sizeof(WCHAR))
|
||||||
wcslen(L"Environment") == Keyword->Length/sizeof(WCHAR)
|
|
||||||
)
|
|
||||||
{
|
{
|
||||||
*ParameterValue = ExAllocatePool(PagedPool, sizeof(NDIS_CONFIGURATION_PARAMETER));
|
*ParameterValue = ExAllocatePool(PagedPool, sizeof(NDIS_CONFIGURATION_PARAMETER));
|
||||||
if(!*ParameterValue)
|
if(!*ParameterValue)
|
||||||
|
@ -483,10 +481,8 @@ NdisReadConfiguration(
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(
|
if(!wcsncmp(Keyword->Buffer, L"ProcessorType", Keyword->Length/sizeof(WCHAR)) &&
|
||||||
!wcsncmp(Keyword->Buffer, L"ProcessorType", Keyword->Length/sizeof(WCHAR)) &&
|
wcslen(L"ProcessorType") == Keyword->Length/sizeof(WCHAR))
|
||||||
wcslen(L"ProcessorType") == Keyword->Length/sizeof(WCHAR)
|
|
||||||
)
|
|
||||||
{
|
{
|
||||||
*ParameterValue = ExAllocatePool(PagedPool, sizeof(NDIS_CONFIGURATION_PARAMETER));
|
*ParameterValue = ExAllocatePool(PagedPool, sizeof(NDIS_CONFIGURATION_PARAMETER));
|
||||||
if(!*ParameterValue)
|
if(!*ParameterValue)
|
||||||
|
@ -519,10 +515,8 @@ NdisReadConfiguration(
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(
|
if(!wcsncmp(Keyword->Buffer, L"NdisVersion", Keyword->Length/sizeof(WCHAR)) &&
|
||||||
!wcsncmp(Keyword->Buffer, L"NdisVersion", Keyword->Length/sizeof(WCHAR)) &&
|
wcslen(L"NdisVersion") == Keyword->Length/sizeof(WCHAR))
|
||||||
wcslen(L"NdisVersion") == Keyword->Length/sizeof(WCHAR)
|
|
||||||
)
|
|
||||||
{
|
{
|
||||||
*ParameterValue = ExAllocatePool(PagedPool, sizeof(NDIS_CONFIGURATION_PARAMETER));
|
*ParameterValue = ExAllocatePool(PagedPool, sizeof(NDIS_CONFIGURATION_PARAMETER));
|
||||||
if(!*ParameterValue)
|
if(!*ParameterValue)
|
||||||
|
@ -613,7 +607,7 @@ NdisReadConfiguration(
|
||||||
|
|
||||||
(*ParameterValue)->ParameterType = NdisParameterBinary;
|
(*ParameterValue)->ParameterType = NdisParameterBinary;
|
||||||
|
|
||||||
Buffer = ExAllocatePool(NonPagedPool, KeyInformation->DataLength);
|
Buffer = ExAllocatePool(PagedPool, KeyInformation->DataLength);
|
||||||
if (!Buffer)
|
if (!Buffer)
|
||||||
{
|
{
|
||||||
NDIS_DbgPrint(MIN_TRACE, ("Insufficient resources.\n"));
|
NDIS_DbgPrint(MIN_TRACE, ("Insufficient resources.\n"));
|
||||||
|
@ -634,7 +628,7 @@ NdisReadConfiguration(
|
||||||
|
|
||||||
(*ParameterValue)->ParameterType = NdisParameterMultiString;
|
(*ParameterValue)->ParameterType = NdisParameterMultiString;
|
||||||
|
|
||||||
Buffer = ExAllocatePool(NonPagedPool, KeyInformation->DataLength);
|
Buffer = ExAllocatePool(PagedPool, KeyInformation->DataLength);
|
||||||
if (!Buffer)
|
if (!Buffer)
|
||||||
{
|
{
|
||||||
NDIS_DbgPrint(MIN_TRACE, ("Insufficient resources.\n"));
|
NDIS_DbgPrint(MIN_TRACE, ("Insufficient resources.\n"));
|
||||||
|
@ -678,7 +672,7 @@ NdisReadConfiguration(
|
||||||
|
|
||||||
(*ParameterValue)->ParameterType = NdisParameterString;
|
(*ParameterValue)->ParameterType = NdisParameterString;
|
||||||
|
|
||||||
Buffer = ExAllocatePool(NonPagedPool, KeyInformation->DataLength);
|
Buffer = ExAllocatePool(PagedPool, KeyInformation->DataLength);
|
||||||
if (!Buffer)
|
if (!Buffer)
|
||||||
{
|
{
|
||||||
NDIS_DbgPrint(MIN_TRACE, ("Insufficient resources.\n"));
|
NDIS_DbgPrint(MIN_TRACE, ("Insufficient resources.\n"));
|
||||||
|
|
Loading…
Reference in a new issue