From f315d8b0c4c5a2fc5e8b922b82e92efa52964ff0 Mon Sep 17 00:00:00 2001 From: Alexandre Julliard Date: Mon, 11 Jul 2005 18:39:49 +0000 Subject: [PATCH] A NULL module handle means 'main exe' in GetProcAddress too. --- dlls/kernel/module.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/dlls/kernel/module.c b/dlls/kernel/module.c index ddbed04501..fae746a87c 100644 --- a/dlls/kernel/module.c +++ b/dlls/kernel/module.c @@ -810,6 +810,8 @@ FARPROC WINAPI GetProcAddress( HMODULE hModule, LPCSTR function ) NTSTATUS nts; FARPROC fp; + if (!hModule) hModule = NtCurrentTeb()->Peb->ImageBaseAddress; + if (HIWORD(function)) { ANSI_STRING str;