|
|
@ -658,17 +658,12 @@ bool AppInit2(boost::thread_group& threadGroup, CScheduler& scheduler) |
|
|
|
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 || LOBYTE(wsadata.wVersion ) != 2 || HIBYTE(wsadata.wVersion) != 2) |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
return InitError(strprintf("Error: Winsock library failed to start (WSAStartup returned error %d)", ret)); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
#endif |
|
|
|
#endif |
|
|
|
#ifndef WIN32 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (!SetupNetworking()) |
|
|
|
|
|
|
|
return InitError("Error: Initializing networking failed"); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#ifndef WIN32 |
|
|
|
if (GetBoolArg("-sysperms", false)) { |
|
|
|
if (GetBoolArg("-sysperms", false)) { |
|
|
|
#ifdef ENABLE_WALLET |
|
|
|
#ifdef ENABLE_WALLET |
|
|
|
if (!GetBoolArg("-disablewallet", false)) |
|
|
|
if (!GetBoolArg("-disablewallet", false)) |
|
|
|