Author: akhaldi Date: Sun Sep 14 15:31:58 2014 New Revision: 64149
URL: http://svn.reactos.org/svn/reactos?rev=64149&view=rev Log: [MSI] * Implement a correct CUSTOMPROC_wrapper wrapper for MSVC.
Modified: trunk/reactos/dll/win32/msi/msvchelper.h
Modified: trunk/reactos/dll/win32/msi/msvchelper.h URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/msvchelper.h?... ============================================================================== --- trunk/reactos/dll/win32/msi/msvchelper.h [iso-8859-1] (original) +++ trunk/reactos/dll/win32/msi/msvchelper.h [iso-8859-1] Sun Sep 14 15:31:58 2014 @@ -4,10 +4,22 @@
typedef unsigned int (__stdcall *__MSVC__MsiCustomActionEntryPoint)(unsigned int);
-__inline unsigned int CUSTOMPROC_wrapper(__MSVC__MsiCustomActionEntryPoint proc, unsigned int handle) +static +__declspec(naked) +unsigned int +__cdecl +CUSTOMPROC_wrapper(__MSVC__MsiCustomActionEntryPoint proc, unsigned int handle) { -#pragma message("warning: CUSTOMPROC_wrapper might not be correct") - return proc(handle); + __asm + { + push ebp + mov ebp, esp + push dword ptr [ebp + 12] + mov eax, dword ptr [ebp + 8] + call eax + leave + ret + } }
#endif