mirror of
https://github.com/goatcorp/Dalamud.git
synced 2025-12-12 10:17:22 +01:00
disable veh and symbolhandler for linux
This commit is contained in:
parent
32896611d5
commit
bddc1e1365
2 changed files with 26 additions and 5 deletions
|
|
@ -9,6 +9,18 @@
|
||||||
|
|
||||||
HMODULE g_hModule;
|
HMODULE g_hModule;
|
||||||
|
|
||||||
|
bool is_running_on_linux()
|
||||||
|
{
|
||||||
|
HMODULE hntdll = GetModuleHandleW(L"ntdll.dll");
|
||||||
|
if (!hntdll) // not running on NT
|
||||||
|
return true;
|
||||||
|
|
||||||
|
FARPROC pwine_get_version = GetProcAddress(hntdll, "wine_get_version");
|
||||||
|
FARPROC pwine_get_host_version = GetProcAddress(hntdll, "wine_get_host_version");
|
||||||
|
|
||||||
|
return pwine_get_version != nullptr || pwine_get_host_version != nullptr;
|
||||||
|
}
|
||||||
|
|
||||||
DllExport DWORD WINAPI Initialize(LPVOID lpParam)
|
DllExport DWORD WINAPI Initialize(LPVOID lpParam)
|
||||||
{
|
{
|
||||||
#ifndef NDEBUG
|
#ifndef NDEBUG
|
||||||
|
|
@ -48,9 +60,16 @@ DllExport DWORD WINAPI Initialize(LPVOID lpParam)
|
||||||
// ============================== VEH ======================================== //
|
// ============================== VEH ======================================== //
|
||||||
|
|
||||||
printf("Initializing VEH... ");
|
printf("Initializing VEH... ");
|
||||||
if (veh::add_handler())
|
if(is_running_on_linux())
|
||||||
printf("Done!\n");
|
{
|
||||||
else printf("Failed!\n");
|
printf("Failed! [Disabled for Wine]\n");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (veh::add_handler())
|
||||||
|
printf("Done!\n");
|
||||||
|
else printf("Failed!\n");
|
||||||
|
}
|
||||||
|
|
||||||
// =========================================================================== //
|
// =========================================================================== //
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -12,6 +12,7 @@ using Dalamud.Configuration.Internal;
|
||||||
using Dalamud.Game;
|
using Dalamud.Game;
|
||||||
using Dalamud.Logging.Internal;
|
using Dalamud.Logging.Internal;
|
||||||
using Dalamud.Support;
|
using Dalamud.Support;
|
||||||
|
using Dalamud.Utility;
|
||||||
using Newtonsoft.Json;
|
using Newtonsoft.Json;
|
||||||
using PInvoke;
|
using PInvoke;
|
||||||
using Serilog;
|
using Serilog;
|
||||||
|
|
@ -75,8 +76,9 @@ namespace Dalamud
|
||||||
|
|
||||||
// This is due to GitHub not supporting TLS 1.0, so we enable all TLS versions globally
|
// This is due to GitHub not supporting TLS 1.0, so we enable all TLS versions globally
|
||||||
ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls11 | SecurityProtocolType.Tls12 | SecurityProtocolType.Tls;
|
ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls11 | SecurityProtocolType.Tls12 | SecurityProtocolType.Tls;
|
||||||
|
|
||||||
InitSymbolHandler(info);
|
if (!Util.IsLinux())
|
||||||
|
InitSymbolHandler(info);
|
||||||
|
|
||||||
var dalamud = new Dalamud(info, levelSwitch, finishSignal, configuration);
|
var dalamud = new Dalamud(info, levelSwitch, finishSignal, configuration);
|
||||||
Log.Information("Starting a session..");
|
Log.Information("Starting a session..");
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue