fixed calls to NtDuplicateObject
authorThomas Bluemel <thomas@reactsoft.com>
Sat, 10 Dec 2005 17:09:35 +0000 (17:09 +0000)
committerThomas Bluemel <thomas@reactsoft.com>
Sat, 10 Dec 2005 17:09:35 +0000 (17:09 +0000)
svn path=/trunk/; revision=20040

reactos/drivers/net/ndis/ndis/config.c
reactos/lib/kernel32/misc/handle.c
reactos/lib/rtl/registry.c
reactos/subsys/win32k/ntuser/csr.c

index 0a73872..bc9e943 100644 (file)
@@ -180,7 +180,7 @@ NdisOpenConfiguration(
     NDIS_DbgPrint(MAX_TRACE, ("Called\n"));
 
     *Status = ZwDuplicateObject(NtCurrentProcess(), RootKeyHandle,
-                                NtCurrentProcess(), &KeyHandle, 0, FALSE,
+                                NtCurrentProcess(), &KeyHandle, 0, 0,
                                 DUPLICATE_SAME_ACCESS);
     if(!NT_SUCCESS(*Status))
     {
index f3dcba8..3ee219c 100644 (file)
@@ -232,7 +232,7 @@ BOOL STDCALL DuplicateHandle(HANDLE hSourceProcessHandle,
                              hTargetProcessHandle,
                              lpTargetHandle,
                              dwDesiredAccess,
-                             (BOOLEAN)bInheritHandle,
+                             bInheritHandle ? OBJ_INHERIT : 0,
                              dwOptions);
    if (!NT_SUCCESS(Status))
      {
index 08bf006..641e931 100644 (file)
@@ -44,7 +44,7 @@ RtlpGetRegistryHandle(ULONG RelativeTo,
                                 NtCurrentProcess(),
                                 KeyHandle,
                                 0,
-                                FALSE,
+                                0,
                                 DUPLICATE_SAME_ACCESS);
 #ifndef NDEBUG
       if(!NT_SUCCESS(Status))
index c58e69e..b7b0eb9 100644 (file)
@@ -121,7 +121,7 @@ CsrInsertObject(HANDLE ObjectHandle,
                                  CsrProcessHandle,
                                  Handle,
                                  DesiredAccess,
-                                 TRUE,
+                                 OBJ_INHERIT,
                                  0);
 
       /* Close our handle to CSRSS */