|
|
@ -453,6 +453,14 @@ bool AppInit2(boost::thread_group& threadGroup) |
|
|
|
typedef BOOL (WINAPI *PSETPROCDEPPOL)(DWORD); |
|
|
|
typedef BOOL (WINAPI *PSETPROCDEPPOL)(DWORD); |
|
|
|
PSETPROCDEPPOL setProcDEPPol = (PSETPROCDEPPOL)GetProcAddress(GetModuleHandleA("Kernel32.dll"), "SetProcessDEPPolicy"); |
|
|
|
PSETPROCDEPPOL setProcDEPPol = (PSETPROCDEPPOL)GetProcAddress(GetModuleHandleA("Kernel32.dll"), "SetProcessDEPPolicy"); |
|
|
|
if (setProcDEPPol != NULL) setProcDEPPol(PROCESS_DEP_ENABLE); |
|
|
|
if (setProcDEPPol != NULL) setProcDEPPol(PROCESS_DEP_ENABLE); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Initialize Windows Sockets
|
|
|
|
|
|
|
|
WSADATA wsadata; |
|
|
|
|
|
|
|
int ret = WSAStartup(MAKEWORD(2,2), &wsadata); |
|
|
|
|
|
|
|
if (ret != NO_ERROR) |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
return InitError(strprintf("Error: TCP/IP socket library failed to start (WSAStartup returned error %d)", ret)); |
|
|
|
|
|
|
|
} |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
#ifndef WIN32 |
|
|
|
#ifndef WIN32 |
|
|
|
umask(077); |
|
|
|
umask(077); |
|
|
|