diff --git a/reactos/lib/kernel32/mem/section.c b/reactos/lib/kernel32/mem/section.c index e2fc7376ceb..d6734e8422d 100644 --- a/reactos/lib/kernel32/mem/section.c +++ b/reactos/lib/kernel32/mem/section.c @@ -77,7 +77,7 @@ CreateFileMappingA(HANDLE hFile, InitializeObjectAttributes(&ObjectAttributes, (lpName ? &UnicodeName : NULL), 0, - hBaseDir, + (lpName ? hBaseDir : NULL), SecurityDescriptor); Status = NtCreateSection(&SectionHandle, @@ -155,7 +155,7 @@ CreateFileMappingW(HANDLE hFile, InitializeObjectAttributes(&ObjectAttributes, (lpName ? &UnicodeName : NULL), 0, - hBaseDir, + (lpName ? hBaseDir : NULL), SecurityDescriptor); Status = NtCreateSection(&SectionHandle, diff --git a/reactos/lib/kernel32/synch/event.c b/reactos/lib/kernel32/synch/event.c index 6f8d80baf46..f5da06033cb 100644 --- a/reactos/lib/kernel32/synch/event.c +++ b/reactos/lib/kernel32/synch/event.c @@ -77,7 +77,7 @@ CreateEventW(LPSECURITY_ATTRIBUTES lpEventAttributes, InitializeObjectAttributes(&ObjectAttributes, (lpName ? &UnicodeName : NULL), 0, - hBaseDir, + (lpName ? hBaseDir : NULL), NULL); if (lpEventAttributes != NULL) diff --git a/reactos/lib/kernel32/synch/mutex.c b/reactos/lib/kernel32/synch/mutex.c index 20c3293da1d..854901d3a9e 100644 --- a/reactos/lib/kernel32/synch/mutex.c +++ b/reactos/lib/kernel32/synch/mutex.c @@ -76,7 +76,7 @@ CreateMutexW(LPSECURITY_ATTRIBUTES lpMutexAttributes, InitializeObjectAttributes(&ObjectAttributes, (lpName ? &UnicodeName : NULL), 0, - hBaseDir, + (lpName ? hBaseDir : NULL), NULL); if (lpMutexAttributes != NULL) diff --git a/reactos/lib/kernel32/synch/sem.c b/reactos/lib/kernel32/synch/sem.c index aa5124d92f6..0e39f1cbeb0 100644 --- a/reactos/lib/kernel32/synch/sem.c +++ b/reactos/lib/kernel32/synch/sem.c @@ -77,7 +77,7 @@ CreateSemaphoreW(LPSECURITY_ATTRIBUTES lpSemaphoreAttributes, InitializeObjectAttributes(&ObjectAttributes, (lpName ? &UnicodeName : NULL), 0, - hBaseDir, + (lpName ? hBaseDir : NULL), NULL); if (lpSemaphoreAttributes != NULL) diff --git a/reactos/lib/kernel32/synch/timer.c b/reactos/lib/kernel32/synch/timer.c index ebfdaa31413..fd28a112d1a 100644 --- a/reactos/lib/kernel32/synch/timer.c +++ b/reactos/lib/kernel32/synch/timer.c @@ -38,7 +38,7 @@ CreateWaitableTimerW(LPSECURITY_ATTRIBUTES lpTimerAttributes, InitializeObjectAttributes(&ObjectAttributes, (lpTimerName ? &UnicodeName : NULL), 0, - hBaseDir, + (lpTimerName ? hBaseDir : NULL), NULL); if (lpTimerAttributes != NULL) diff --git a/reactos/ntoskrnl/io/file.c b/reactos/ntoskrnl/io/file.c index 29b442ea467..01543780452 100644 --- a/reactos/ntoskrnl/io/file.c +++ b/reactos/ntoskrnl/io/file.c @@ -278,7 +278,7 @@ IopSecurityFile(PVOID ObjectBody, if (FileObject->Flags & FO_DIRECT_DEVICE_OPEN) { /* Get the Device Object */ - DPRINT1("here\n"); + DPRINT("here\n"); DeviceObject = IoGetAttachedDevice(FileObject->DeviceObject); /* Assign the Security Descriptor */ diff --git a/reactos/ntoskrnl/ob/object.c b/reactos/ntoskrnl/ob/object.c index e1628cc5d96..62ab62f7af3 100644 --- a/reactos/ntoskrnl/ob/object.c +++ b/reactos/ntoskrnl/ob/object.c @@ -74,7 +74,11 @@ ObpCaptureObjectName(IN OUT PUNICODE_STRING CapturedName, } /* Fail if anything up to here died */ - if (!NT_SUCCESS(Status)) return Status; + if (!NT_SUCCESS(Status)) + { + DPRINT1("Probing failed\n"); + return Status; + } } else { @@ -228,14 +232,12 @@ ObpCaptureObjectAttributes(IN POBJECT_ATTRIBUTES ObjectAttributes, } else { - #if 0 /*FIXME: FIX KERNEL32 and STUFF!!! */ /* He can't have specified a Root Directory */ if (ObjectCreateInfo->RootDirectory) { DPRINT1("Invalid name\n"); Status = STATUS_OBJECT_NAME_INVALID; } - #endif } fail: