diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/mir_app/src/dll_sniffer.cpp | 4 | ||||
-rw-r--r-- | src/mir_app/src/newplugins.cpp | 4 |
2 files changed, 5 insertions, 3 deletions
diff --git a/src/mir_app/src/dll_sniffer.cpp b/src/mir_app/src/dll_sniffer.cpp index 0b9ea031b9..c341c9e87c 100644 --- a/src/mir_app/src/dll_sniffer.cpp +++ b/src/mir_app/src/dll_sniffer.cpp @@ -123,7 +123,7 @@ MUUID* GetPluginInterfaces(const wchar_t* ptszFileName, bool& bIsPlugin) bHasUnload = true;
else if (!mir_strcmp(szName, "MirandaInterfaces")) {
bHasMuuids = true;
- pIds = (MUUID*)&pSecStart[ ptrFuncList[*ptrOrdRVA]];
+ pIds = (MUUID*)&pSecStart[ptrFuncList[*ptrOrdRVA]];
}
// old plugin, skip it
else if (!mir_strcmp(szName, "MirandaPluginInterfaces"))
@@ -141,7 +141,7 @@ MUUID* GetPluginInterfaces(const wchar_t* ptszFileName, bool& bIsPlugin) for (MUUID* p = pIds; *p != miid_last; p++)
nLength++;
- pResult = (MUUID*)mir_alloc( sizeof(MUUID)*nLength);
+ pResult = (MUUID*)mir_alloc(sizeof(MUUID)*nLength);
if (pResult)
memcpy(pResult, pIds, sizeof(MUUID)*nLength);
}
diff --git a/src/mir_app/src/newplugins.cpp b/src/mir_app/src/newplugins.cpp index 9e93ea32eb..fa83a8ec39 100644 --- a/src/mir_app/src/newplugins.cpp +++ b/src/mir_app/src/newplugins.cpp @@ -121,7 +121,7 @@ static const MUUID pluginBannedList[] = { 0xa0138fc6, 0x4c52, 0x4501, { 0xaf, 0x93, 0x7d, 0x3e, 0x20, 0xbc, 0xae, 0x5b } }, // dbchecker
};
-static bool isPluginBanned(const MUUID& u1)
+static bool isPluginBanned(const MUUID &u1)
{
for (auto &it : pluginBannedList)
if (it == u1)
@@ -271,7 +271,9 @@ static int checkPI(BASIC_PLUGIN_INFO *bpi, PLUGININFOEX *pi) int checkAPI(wchar_t* plugin, BASIC_PLUGIN_INFO* bpi, DWORD dwMirVer, int checkTypeAPI)
{
+ SetErrorMode(SEM_FAILCRITICALERRORS); // disable error messages
HINSTANCE h = LoadLibrary(plugin);
+ SetErrorMode(0); // reset the system default
if (h == nullptr)
return 0;
|