From 3d605b8940cb1f47a8020e156a761bf3f4bd45c8 Mon Sep 17 00:00:00 2001 From: Robbert van der Helm Date: Thu, 16 Apr 2020 15:42:27 +0200 Subject: [PATCH] Change entry point search order Shouldn't matter at all, but `main` is such a generic and ambiguous name it should probably be the last option. --- src/wine-host/plugin-bridge.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wine-host/plugin-bridge.cpp b/src/wine-host/plugin-bridge.cpp index 3b7d358f..fc951e49 100644 --- a/src/wine-host/plugin-bridge.cpp +++ b/src/wine-host/plugin-bridge.cpp @@ -76,7 +76,7 @@ PluginBridge::PluginBridge(std::string plugin_dll_path, // VST plugin entry point functions should be called `VSTPluginMain`, but // there are some older deprecated names that legacy plugins may still use VstEntryPoint vst_entry_point = nullptr; - for (auto name : {"VSTPluginMain", "main", "main_plugin"}) { + for (auto name : {"VSTPluginMain", "main_plugin", "main"}) { vst_entry_point = reinterpret_cast(reinterpret_cast( GetProcAddress(plugin_handle.get(), name)));