diff options
author | Ivo Hinkelmann <ihi@openoffice.org> | 2010-08-03 18:08:43 +0200 |
---|---|---|
committer | Ivo Hinkelmann <ihi@openoffice.org> | 2010-08-03 18:08:43 +0200 |
commit | 8050668b3ac640c3034489984b932192022177c5 (patch) | |
tree | aae5d064b83c7855330940ecf3e1c51457af0065 | |
parent | e153ab256682d70d5ba6a9705ca3b25c3480ff19 (diff) | |
parent | 75d5313a426f26e1dcc505b44406a89a0c5321cd (diff) |
CWS-TOOLING: integrate CWS mhu23ooo/OOO330_m4ooo/OOO330_m3
-rw-r--r-- | sal/osl/w32/salinit.cxx | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/sal/osl/w32/salinit.cxx b/sal/osl/w32/salinit.cxx index 23e3ce834..43b7b8a16 100644 --- a/sal/osl/w32/salinit.cxx +++ b/sal/osl/w32/salinit.cxx @@ -40,6 +40,26 @@ extern "C" { void SAL_CALL sal_detail_initialize(int argc, char ** argv) { + // SetProcessDEPPolicy(PROCESS_DEP_ENABLE); + // SetDllDirectoryW(L""); + // SetSearchPathMode( + // BASE_SEARCH_PATH_ENABLE_SAFE_SEARCHMODE | BASE_SEARCH_PATH_PERMANENT); + HMODULE h = GetModuleHandleW(L"kernel32.dll"); + if (h != 0) { + FARPROC p = GetProcAddress(h, "SetProcessDEPPolicy"); + if (p != 0) { + reinterpret_cast< BOOL (WINAPI *)(DWORD) >(p)(0x00000001); + } + p = GetProcAddress(h, "SetDllDirectoryW"); + if (p != 0) { + reinterpret_cast< BOOL (WINAPI *)(LPCWSTR) >(p)(L""); + } + p = GetProcAddress(h, "SetSearchPathMode"); + if (p != 0) { + reinterpret_cast< BOOL (WINAPI *)(DWORD) >(p)(0x8001); + } + } + WSADATA wsaData; int error; WORD wVersionRequested; |