Author: tfaber
Date: Fri Aug 5 00:50:51 2011
New Revision: 53072
URL:
http://svn.reactos.org/svn/reactos?rev=53072&view=rev
Log:
[CSRSRV]
- Define NDEBUG only once
- Don't define helper macro in the source
- DPRINT fixes
[NTDLL/LDR]
- More verbose DPRINT for initialization failure
Modified:
trunk/reactos/dll/ntdll/ldr/ldrinit.c
trunk/reactos/subsystems/win32/csrss/csrsrv/api/process.c
trunk/reactos/subsystems/win32/csrss/csrsrv/api/wapi.c
trunk/reactos/subsystems/win32/csrss/csrsrv/init.c
trunk/reactos/subsystems/win32/csrss/csrsrv/srv.h
Modified: trunk/reactos/dll/ntdll/ldr/ldrinit.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/ntdll/ldr/ldrinit.c?re…
==============================================================================
--- trunk/reactos/dll/ntdll/ldr/ldrinit.c [iso-8859-1] (original)
+++ trunk/reactos/dll/ntdll/ldr/ldrinit.c [iso-8859-1] Fri Aug 5 00:50:51 2011
@@ -1996,9 +1996,11 @@
LdrpInitFailure(NTSTATUS Status)
{
ULONG Response;
+ PPEB Peb = NtCurrentPeb();
/* Print a debug message */
- DPRINT1("LDR: Process initialization failure; NTSTATUS = %08lx\n",
Status);
+ DPRINT1("LDR: Process initialization failure for %wZ; NTSTATUS = %08lx\n",
+ &Peb->ProcessParameters->ImagePathName, Status);
/* Raise a hard error */
if (!LdrpFatalHardErrorCount)
Modified: trunk/reactos/subsystems/win32/csrss/csrsrv/api/process.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/csrss/csr…
==============================================================================
--- trunk/reactos/subsystems/win32/csrss/csrsrv/api/process.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/csrss/csrsrv/api/process.c [iso-8859-1] Fri Aug 5
00:50:51 2011
@@ -105,7 +105,7 @@
PROCESS_ALL_ACCESS,
&ObjectAttributes,
&ClientId);
- DPRINT1("CSR PRocess: %p Handle: %p\n", pProcessData,
pProcessData->Process);
+ DPRINT1("CSR Process: %p Handle: %p\n", pProcessData,
pProcessData->Process);
if (!NT_SUCCESS(Status))
{
ProcessData[hash] = pProcessData->next;
Modified: trunk/reactos/subsystems/win32/csrss/csrsrv/api/wapi.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/csrss/csr…
==============================================================================
--- trunk/reactos/subsystems/win32/csrss/csrsrv/api/wapi.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/csrss/csrsrv/api/wapi.c [iso-8859-1] Fri Aug 5
00:50:51 2011
@@ -11,8 +11,6 @@
/* INCLUDES ******************************************************************/
#include <srv.h>
-
-#define NDEBUG
#define NDEBUG
#include <debug.h>
@@ -181,7 +179,6 @@
if (!NT_SUCCESS(Status)) return Status;
/* Multiply by 1024 entries and round to page size */
- #define ROUND_UP(n,size) (((ULONG)(n) + (size - 1)) & ~(size - 1)) // hax
CsrSrvSharedSectionSize = ROUND_UP(Size * 1024, CsrNtSysInfo.PageSize);
DPRINT1("Size: %lx\n", CsrSrvSharedSectionSize);
Modified: trunk/reactos/subsystems/win32/csrss/csrsrv/init.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/csrss/csr…
==============================================================================
--- trunk/reactos/subsystems/win32/csrss/csrsrv/init.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/csrss/csrsrv/init.c [iso-8859-1] Fri Aug 5 00:50:51
2011
@@ -514,9 +514,12 @@
Status = CsrSrvCreateSharedSection(Value);
- DPRINT1("Status: %lx\n", Status);
- ASSERT(Status == STATUS_SUCCESS);
-
+ if (Status != STATUS_SUCCESS)
+ {
+ DPRINT1("CsrSrvCreateSharedSection failed with status 0x%08lx\n",
Status);
+ ASSERT(FALSE);
+ }
+
BasepFakeStaticServerData();
return STATUS_SUCCESS;
}
Modified: trunk/reactos/subsystems/win32/csrss/csrsrv/srv.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/csrss/csr…
==============================================================================
--- trunk/reactos/subsystems/win32/csrss/csrsrv/srv.h [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/csrss/csrsrv/srv.h [iso-8859-1] Fri Aug 5 00:50:51
2011
@@ -18,3 +18,7 @@
/* Internal CSRSS Headers */
#include <api.h>
#include <csrplugin.h>
+
+/* Defines */
+#define ROUND_UP(n, align) ROUND_DOWN(((ULONG)n) + (align) - 1, (align))
+#define ROUND_DOWN(n, align) (((ULONG)n) & ~((align) - 1l))