PipProcessPendingObjects
NTSTATUS __stdcall PipProcessPendingObjects(
VOID *hObjectRootKey,
INT64 *FilterFunction,
const WCHAR *a3,
VOID *a4,
VOID *a5,
UINT8 *_2D8,
VOID *FilterContext,
INT64 *CommitFunction,
const WCHAR *a9,
VOID *a10,
VOID *a11,
VOID *a12,
VOID *CommitContext,
INT64 a6,
INT64 a7,
INT64 a8){
VOID **PoolWithTag;
unsigned int v17;
NTSTATUS v21;
unsigned int i;
HPNPCTX *v23;
NTSTATUS v24;
NTSTATUS v25;
__int64 v26;
HPNPCTX *v27;
UINT64 *DesiredAccess;
char v30;
char v31[3];
UINT64 NumberOfBytes;
_HANDLE phkResult[2];
UINT64 pKeyNameLength[66];
NumberOfBytes = 260i64;
PoolWithTag = 0i64;
v30 = 0;
v17 = 0;
*(_QWORD *)phkResult = 0i64;
DesiredAccess = &NumberOfBytes;
v21 = PnpCtxRegEnumKey(hObjectRootKey, (UINT64)hObjectRootKey, 0i64, pKeyNameLength);
for( i = 1; ; ++i )
{
v24 = v21;
if( v21 == -2147483622 || v21 == -1073741444 )
break;
if( v21 < 0 )
goto LABEL_29;
LODWORD(DesiredAccess) = 1;
if( PnpCtxRegOpenKey(
*(&stru_140CF2E80 + 607),
hObjectRootKey,
(WCHAR *)pKeyNameLength,
0i64,
(UINT64)DesiredAccess,
(VOID **)phkResult) >= 0 )
{
if( !FilterFunction )
goto LABEL_8;
v30 = 0;
v24 = ((__int64(__fastcall *)(UINT64 *, _QWORD, _QWORD, char *))FilterFunction)(
pKeyNameLength,
*(_QWORD *)phkResult,
0i64,
&v30);
if( v24 < 0 )
goto LABEL_29;
if( !v30 )
{
LABEL_8:
LODWORD(NumberOfBytes) = v17;
v25 = PnpCtxRegQueryValue(
v23,
*(VOID **)phkResult,
(WCHAR *)L"DependOnFirmware",
(UINT64 *)((char *)&NumberOfBytes + 4),
PoolWithTag,
&NumberOfBytes);
if( v25 == -1073741789 || v25 == -2147483643 )
{
if( PoolWithTag )
ExFreePoolWithTag(PoolWithTag, 0x42706E50u);
v17 = NumberOfBytes;
PoolWithTag = ExAllocatePoolWithTag(1ui64, (unsigned int)NumberOfBytes, 1114664528i64);
if( !PoolWithTag )
return -1073741670;
v25 = PnpCtxRegQueryValue(
v27,
*(VOID **)phkResult,
(WCHAR *)L"DependOnFirmware",
(UINT64 *)((char *)&NumberOfBytes + 4),
PoolWithTag,
&NumberOfBytes);
}
if( v25 == -1073741772 )
{
if( PoolWithTag )
{
if( v17 >= 2 )
*(_WORD *)PoolWithTag = 0;
LABEL_19:
if( PoolWithTag )
{
if( v17 >= 2 )
{
if( *(_WORD *)PoolWithTag )
{
v31[0] = 0;
if( (int)PnpCheckDriverDependencies((wchar_t *)PoolWithTag, v31, v26) < 0 || !v31[0] )
goto LABEL_26;
}
}
}
}
if( ((int(__fastcall *)(UINT64 *, VOID *, _QWORD, _QWORD))a4)(
pKeyNameLength,
hObjectRootKey,
*(_QWORD *)phkResult,
0i64) >= 0 )
--i;
goto LABEL_26;
}
if( v25 < 0 )
goto LABEL_26;
goto LABEL_19;
}
}
LABEL_26:
LODWORD(NumberOfBytes) = 260;
DesiredAccess = &NumberOfBytes;
v21 = PnpCtxRegEnumKey(v23, (UINT64)hObjectRootKey, (WCHAR *)i, pKeyNameLength);
}
v24 = 0;
LABEL_29:
if( PoolWithTag )
ExFreePoolWithTag(PoolWithTag, 0x42706E50u);
return v24;
}Referenced by:
No references.