Author: jimtabor
Date: Mon Jul 13 07:37:00 2009
New Revision: 41936
URL:
http://svn.reactos.org/svn/reactos?rev=41936&view=rev
Log:
- Implement NtUserInitializeClientPfnArrays, tested and will be needed in later commits.
Modified:
trunk/reactos/subsystems/win32/win32k/ntuser/ntstubs.c
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/ntstubs.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/ntuser/ntstubs.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/ntuser/ntstubs.c [iso-8859-1] Mon Jul 13
07:37:00 2009
@@ -364,9 +364,35 @@
PPFNCLIENTWORKER pfnClientWorker,
HINSTANCE hmodUser)
{
- UNIMPLEMENTED
-
- return STATUS_UNSUCCESSFUL;
+ NTSTATUS Status = STATUS_SUCCESS;
+ DPRINT("Enter NtUserInitializeClientPfnArrays User32 0x%x\n",hmodUser);
+ UserEnterExclusive();
+
+ _SEH2_TRY
+ {
+ ProbeForRead( pfnClientA, sizeof(PFNCLIENT), 1);
+ ProbeForRead( pfnClientW, sizeof(PFNCLIENT), 1);
+ ProbeForRead( pfnClientWorker, sizeof(PFNCLIENTWORKER), 1);
+ RtlCopyMemory(&gpsi->apfnClientA, pfnClientA, sizeof(PFNCLIENT));
+ RtlCopyMemory(&gpsi->apfnClientW, pfnClientW, sizeof(PFNCLIENT));
+ RtlCopyMemory(&gpsi->apfnClientWorker, pfnClientWorker,
sizeof(PFNCLIENTWORKER));
+
+ hModClient = hmodUser;
+ }
+ _SEH2_EXCEPT(EXCEPTION_EXECUTE_HANDLER)
+ {
+ Status =_SEH2_GetExceptionCode();
+ }
+ _SEH2_END
+
+ if (!NT_SUCCESS(Status))
+ {
+ DPRINT1("Failed reading Client Pfns from user space.\n");
+ SetLastNtError(Status);
+ }
+
+ UserLeave();
+ return Status;
}
DWORD