From: Hermès Bélusca-Maïto Date: Sat, 17 Jun 2017 20:13:17 +0000 (+0000) Subject: Just use REG_FORCE_UNLOAD since we're at it. X-Git-Tag: ReactOS-0.4.6~277 X-Git-Url: https://git.reactos.org/?p=reactos.git;a=commitdiff_plain;h=7f8dc7dfccea340251d5f135287a4a0236db9a76 Just use REG_FORCE_UNLOAD since we're at it. svn path=/trunk/; revision=75079 --- diff --git a/rostests/apitests/ntdll/NtLoadUnloadKey.c b/rostests/apitests/ntdll/NtLoadUnloadKey.c index 0202231da7c..011d5304d1f 100644 --- a/rostests/apitests/ntdll/NtLoadUnloadKey.c +++ b/rostests/apitests/ntdll/NtLoadUnloadKey.c @@ -22,7 +22,9 @@ #define REG_CREATED_NEW_KEY 1 #define REG_OPENED_EXISTING_KEY 2 -/* Vista+ */ +#define REG_FORCE_UNLOAD 1 + +/* Vista+ ntstatus.h */ #define STATUS_HIVE_UNLOADED ((NTSTATUS)0xC0000425) #if 1 @@ -526,7 +528,7 @@ START_TEST(NtLoadUnloadKey) ok_ntstatus(Status, STATUS_SUCCESS); /* Force-unmount the hive, with the handle key still opened */ - Status = DisconnectRegistry(NULL, RegistryHives[0].RegMountPoint, 1 /* REG_FORCE_UNLOAD */); + Status = DisconnectRegistry(NULL, RegistryHives[0].RegMountPoint, REG_FORCE_UNLOAD); DPRINT1("Force-unmounting '%S' %s\n", RegistryHives[0].RegMountPoint, NT_SUCCESS(Status) ? "succeeded" : "failed"); ok_hex(Status, STATUS_SUCCESS); @@ -600,7 +602,7 @@ START_TEST(NtLoadUnloadKey) ok_ntstatus(Status, STATUS_SUCCESS); /* Force-unmount the hive (it is already unmounted), this should fail */ - Status = DisconnectRegistry(NULL, RegistryHives[0].RegMountPoint, 1 /* REG_FORCE_UNLOAD */); + Status = DisconnectRegistry(NULL, RegistryHives[0].RegMountPoint, REG_FORCE_UNLOAD); DPRINT1("Force-unmounting '%S' %s\n", RegistryHives[0].RegMountPoint, NT_SUCCESS(Status) ? "succeeded" : "failed"); ok_hex(Status, STATUS_INVALID_PARAMETER);