[MKHIVE/USETUP]
[reactos.git] / reactos / base / setup / usetup / interface / devinst.c
index f5ae9c0..8ea6444 100644 (file)
@@ -81,7 +81,7 @@ InstallDriver(
     RtlCopyMemory(FullImagePath, PathPrefix.Buffer, PathPrefix.MaximumLength);
     wcscat(FullImagePath, ImagePath);
 
-    DPRINT1("Using driver '%S' for device '%S'\n", ImagePath, DeviceId);;
+    DPRINT("Using driver '%S' for device '%S'\n", ImagePath, DeviceId);
 
     /* Create service key */
     RtlInitUnicodeString(&StringU, Driver);
@@ -311,7 +311,7 @@ EventThread(IN LPVOID lpParameter)
     hInf = *(HINF *)lpParameter;
 
     InitializeObjectAttributes(&ObjectAttributes, &EnumU, OBJ_CASE_INSENSITIVE, NULL, NULL);
-    Status = NtOpenKey(&hEnum, 0, &ObjectAttributes);
+    Status = NtOpenKey(&hEnum, KEY_QUERY_VALUE, &ObjectAttributes);
     if (!NT_SUCCESS(Status))
     {
         DPRINT1("NtOpenKey('%wZ') failed with status 0x%08lx\n", &EnumU, Status);
@@ -366,9 +366,9 @@ EventThread(IN LPVOID lpParameter)
 
         /* Process the pnp event */
         DPRINT("Received PnP Event\n");
-        if (IsEqualIID(&PnpEvent->EventGuid, (REFGUID)&GUID_DEVICE_ARRIVAL))
+        if (IsEqualIID(&PnpEvent->EventGuid, (REFGUID)&GUID_DEVICE_ENUMERATED))
         {
-            DPRINT1("Device arrival event: %S\n", PnpEvent->TargetDevice.DeviceIds);
+            DPRINT("Device arrival event: %S\n", PnpEvent->TargetDevice.DeviceIds);
             InstallDevice(hInf, hEnum, hServices, PnpEvent->TargetDevice.DeviceIds);
         }
         else