Module: wine Branch: master Commit: 40509127a44ff6ee052afa17f44337cfa5515641 URL: http://source.winehq.org/git/wine.git/?a=commit;h=40509127a44ff6ee052afa17f4...
Author: Detlef Riekenberg wine.dev@web.de Date: Fri Mar 19 12:28:53 2010 +0100
msvcr90: Implement _initterm_e.
---
dlls/msvcr90/msvcr90.c | 32 ++++++++++++++++++++++++++++++++ dlls/msvcr90/msvcr90.spec | 2 +- 2 files changed, 33 insertions(+), 1 deletions(-)
diff --git a/dlls/msvcr90/msvcr90.c b/dlls/msvcr90/msvcr90.c index 4bef02c..e7baa6f 100644 --- a/dlls/msvcr90/msvcr90.c +++ b/dlls/msvcr90/msvcr90.c @@ -22,7 +22,15 @@
#include "windef.h" #include "winbase.h" +#include "wine/debug.h"
+WINE_DEFAULT_DEBUG_CHANNEL(msvcr90); + +typedef int (CDECL *_INITTERM_E_FN)(void); + +/********************************************************************* + * DllMain (MSVCR90.@) + */ BOOL WINAPI DllMain(HINSTANCE hdll, DWORD reason, LPVOID reserved) { switch (reason) @@ -35,3 +43,27 @@ BOOL WINAPI DllMain(HINSTANCE hdll, DWORD reason, LPVOID reserved) } return TRUE; } + + +/********************************************************************* + * _initterm_e (MSVCR90.@) + * + * call an array of application initialization functions and report the return value + */ +int CDECL _initterm_e(_INITTERM_E_FN *table, _INITTERM_E_FN *end) +{ + int res = 0; + + TRACE("(%p, %p)\n", table, end); + + while (!res && table < end) { + if (*table) { + res = (**table)(); + if (res) + TRACE("function %p failed: 0x%x\n", *table, res); + + } + table++; + } + return res; +} diff --git a/dlls/msvcr90/msvcr90.spec b/dlls/msvcr90/msvcr90.spec index 27ad21d..32c4688 100644 --- a/dlls/msvcr90/msvcr90.spec +++ b/dlls/msvcr90/msvcr90.spec @@ -517,7 +517,7 @@ @ stub _i64tow_s @ stub _initptd @ cdecl _initterm(ptr ptr) msvcrt._initterm -@ stub _initterm_e +@ cdecl _initterm_e(ptr ptr) @ stub _inp @ stub _inpd @ stub _inpw