mirror of
https://github.com/ApfelTeeSaft/reactos.git
synced 2026-08-30 12:23:28 +00:00
Set the ConfigFlags value in registry if not present
svn path=/trunk/; revision=20189
This commit is contained in:
@@ -996,7 +996,7 @@ IopSetDeviceInstanceData(HANDLE InstanceKey,
|
||||
UNICODE_STRING KeyName;
|
||||
HANDLE LogConfKey;
|
||||
ULONG ResCount;
|
||||
ULONG ListSize;
|
||||
ULONG ListSize, ResultLength;
|
||||
NTSTATUS Status;
|
||||
|
||||
DPRINT("IopSetDeviceInstanceData() called\n");
|
||||
@@ -1051,6 +1051,26 @@ IopSetDeviceInstanceData(HANDLE InstanceKey,
|
||||
ZwClose(LogConfKey);
|
||||
}
|
||||
|
||||
/* Set the 'ConfigFlags' value */
|
||||
RtlInitUnicodeString(&KeyName, L"ConfigFlags");
|
||||
Status = ZwQueryValueKey(InstanceKey,
|
||||
&KeyName,
|
||||
KeyValueBasicInformation,
|
||||
NULL,
|
||||
0,
|
||||
&ResultLength);
|
||||
if (Status == STATUS_OBJECT_NAME_NOT_FOUND)
|
||||
{
|
||||
/* Write the default value */
|
||||
ULONG DefaultConfigFlags = 0;
|
||||
Status = ZwSetValueKey(InstanceKey,
|
||||
&KeyName,
|
||||
0,
|
||||
REG_DWORD,
|
||||
&DefaultConfigFlags,
|
||||
sizeof(DefaultConfigFlags));
|
||||
}
|
||||
|
||||
#if 0
|
||||
if (DeviceNode->PhysicalDeviceObject != NULL)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user