Author: greatlrd
Date: Mon Mar 5 18:11:23 2007
New Revision: 25999
URL:
http://svn.reactos.org/svn/reactos?rev=25999&view=rev
Log:
merge 25998
Modified:
branches/ros-branch-0_3_1/reactos/subsystems/win32/win32k/objects/dc.c
Modified: branches/ros-branch-0_3_1/reactos/subsystems/win32/win32k/objects/dc.c
URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_3_1/reactos/subsys…
==============================================================================
--- branches/ros-branch-0_3_1/reactos/subsystems/win32/win32k/objects/dc.c (original)
+++ branches/ros-branch-0_3_1/reactos/subsystems/win32/win32k/objects/dc.c Mon Mar 5
18:11:23 2007
@@ -811,6 +811,26 @@
RtlInitUnicodeString(&StdDriver, L"DISPLAY");
+ if (Driver != NULL)
+ {
+ DPRINT1("NAME Driver: %wZ\n", Driver);
+ }
+ else
+ {
+ DPRINT1("NAME Driver: NULL\n", Driver);
+ }
+
+
+ if (Driver != NULL)
+ {
+ DPRINT1("NAME Device: %wZ\n", Device);
+ }
+ else
+ {
+ DPRINT1("NAME Device: NULL\n", Device);
+ }
+
+
if (NULL == Driver || 0 == RtlCompareUnicodeString(Driver, &StdDriver, TRUE))
{
if (CreateAsIC)
@@ -853,7 +873,8 @@
if (Driver != NULL && Driver->Buffer != NULL)
{
- DPRINT("NAME: %wZ\n", Driver); // FIXME: Should not crash if NULL
+ if (Driver!=NULL)
+ DPRINT1("NAME: %wZ\n", Driver);
}
/* Allocate a DC object */
@@ -962,9 +983,12 @@
Status = IntSafeCopyUnicodeString(&SafeDevice, Device);
if(!NT_SUCCESS(Status))
{
- RtlFreeUnicodeString(&SafeDriver);
- SetLastNtError(Status);
- return NULL;
+ /* FIXME workaround for a real bug */
+ // RtlFreeUnicodeString(&SafeDriver);
+ // SetLastNtError(Status);
+ // DPRINT1("fail3\n");
+ // return NULL;
+ Device = NULL;
}
}
@@ -1780,6 +1804,7 @@
}
GDIOBJ_UnlockObjByPtr(GdiHandleTable, GdiObject);
+
return Result;
}