From b172c4bbc75cdad0e8ccd22292aa671ba43cac45 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Wed, 18 Apr 2018 18:14:33 +0300 Subject: PLUGIN<> to half-automatically calculate the dll's g_hInstance and pass it inside --- protocols/Tox/src/main.cpp | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'protocols/Tox/src') diff --git a/protocols/Tox/src/main.cpp b/protocols/Tox/src/main.cpp index 88a13bc13b..ec6ae99f82 100644 --- a/protocols/Tox/src/main.cpp +++ b/protocols/Tox/src/main.cpp @@ -21,12 +21,7 @@ PLUGININFOEX pluginInfo = {0x272a3e, 0xf5fa, 0x4090, {0x8b, 0x67, 0x3e, 0x62, 0xac, 0x1e, 0xe0, 0xb4}} }; -DWORD WINAPI DllMain(HINSTANCE hInstance, DWORD, LPVOID) -{ - g_hInstance = hInstance; - - return TRUE; -} +extern "C" _pfnCrtInit _pRawDllMain = &CMPlugin::RawDllMain; extern "C" __declspec(dllexport) PLUGININFOEX* MirandaPluginInfoEx(DWORD) { -- cgit v1.2.3