summaryrefslogtreecommitdiff
path: root/sal
diff options
context:
space:
mode:
authortono <tono@openoffice.org>2010-05-31 21:53:32 +0900
committertono <tono@openoffice.org>2010-05-31 21:53:32 +0900
commitcdce30bdbfe22f4b24ff2b2d96881506dd65e277 (patch)
tree9e513f852b3867bc777b86c5f07a653c70bb2cc0 /sal
parent692b763ac1adfdc7d93a41e711a08b9d5c43a726 (diff)
i#111958: MinGW port enhancement: runtime-pseude-reloc-v2
Diffstat (limited to 'sal')
-rw-r--r--sal/systools/win32/uwinapi/DllMain.cpp9
-rw-r--r--sal/systools/win32/uwinapi/sntprintf.c2
2 files changed, 5 insertions, 6 deletions
diff --git a/sal/systools/win32/uwinapi/DllMain.cpp b/sal/systools/win32/uwinapi/DllMain.cpp
index ff42ebf1f1dd..94f6c34fec24 100644
--- a/sal/systools/win32/uwinapi/DllMain.cpp
+++ b/sal/systools/win32/uwinapi/DllMain.cpp
@@ -223,14 +223,13 @@ extern "C" BOOL WINAPI DllMain( HMODULE hModule, DWORD dwReason, LPVOID )
{
case DLL_PROCESS_ATTACH:
UWINAPI_BaseAddress = hModule;
+#ifdef __MINGW32__
+ return TRUE;
+#else
return DisableThreadLibraryCalls( hModule );
+#endif
default:
return TRUE;
}
}
-
-
-
-
-
diff --git a/sal/systools/win32/uwinapi/sntprintf.c b/sal/systools/win32/uwinapi/sntprintf.c
index 25e9c6df1f41..69d47821311c 100644
--- a/sal/systools/win32/uwinapi/sntprintf.c
+++ b/sal/systools/win32/uwinapi/sntprintf.c
@@ -10,7 +10,7 @@
#pragma warning(disable:4273) // inconsistent dll linkage
#endif
-#if _MSC_VER < 1300
+#if (defined(_MSC_VER) && (_MSC_VER < 1300)) || (defined(__MINGW32_VERSION) && ((__MINGW32_MAJOR_VERSION < 3)||((__MINGW32_MAJOR_VERSION == 3)&&(__MINGW32_MINOR_VERSION < 18))))
/* The non-debug versions of _vscprintf/_scprintf are just calls
to _vsprintf/_sprintf with string buffer pointer set to NULL,