[ros-diffs] [tretiakov] 26231: Implement EngUnloadImage

tretiakov at svn.reactos.org tretiakov at svn.reactos.org
Sun Apr 1 19:20:50 CEST 2007


Author: tretiakov
Date: Sun Apr  1 21:20:50 2007
New Revision: 26231

URL: http://svn.reactos.org/svn/reactos?rev=26231&view=rev
Log:
Implement EngUnloadImage

Modified:
    trunk/reactos/subsystems/win32/win32k/ldr/loader.c

Modified: trunk/reactos/subsystems/win32/win32k/ldr/loader.c
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ldr/loader.c?rev=26231&r1=26230&r2=26231&view=diff
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/ldr/loader.c (original)
+++ trunk/reactos/subsystems/win32/win32k/ldr/loader.c Sun Apr  1 21:20:50 2007
@@ -213,10 +213,28 @@
   // FIXME: should load as readonly
 
   RtlInitUnicodeString (&GdiDriverInfo.DriverName, ModuleName);
-  Status = ZwSetSystemInformation (SystemLoadGdiDriverInformation, &GdiDriverInfo, sizeof(SYSTEM_GDI_DRIVER_INFORMATION));
+  Status = ZwSetSystemInformation (SystemLoadGdiDriverInformation, 
+    &GdiDriverInfo, sizeof(SYSTEM_GDI_DRIVER_INFORMATION));
   if (!NT_SUCCESS(Status)) return NULL;
 
   return (HANDLE)GdiDriverInfo.ImageAddress;
 }
 
+VOID
+STDCALL
+EngUnloadImage ( IN HANDLE hModule )
+{
+  NTSTATUS Status;
+  
+  DPRINT1("hModule=%x\n", hModule);
+  Status = ZwSetSystemInformation(SystemUnloadGdiDriverInformation, 
+    &hModule, sizeof(HANDLE));
+  
+  if(!NT_SUCCESS(Status))
+  {
+    DPRINT1("%s: ZwSetSystemInformation failed with status %x.", 
+      __FUNCTION__, Status);
+  }  
+}
+
 /* EOF */




More information about the Ros-diffs mailing list