summaryrefslogtreecommitdiff
path: root/plugins/MirLua/src/mlua_script_loader.cpp
diff options
context:
space:
mode:
authorAlexander Lantsev <aunsane@gmail.com>2016-01-03 21:30:23 +0000
committerAlexander Lantsev <aunsane@gmail.com>2016-01-03 21:30:23 +0000
commitf8b41d51f1b760a433c2dbf997ed852b7dd94945 (patch)
treec7a7cb6f6fc8b8bbdc8e63b9c67fe584f7470a9a /plugins/MirLua/src/mlua_script_loader.cpp
parent99d0352e7dd98a8d05247f1a446d212499b08a50 (diff)
MirLua: fixed script loading
git-svn-id: http://svn.miranda-ng.org/main/trunk@16014 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/MirLua/src/mlua_script_loader.cpp')
-rw-r--r--plugins/MirLua/src/mlua_script_loader.cpp14
1 files changed, 3 insertions, 11 deletions
diff --git a/plugins/MirLua/src/mlua_script_loader.cpp b/plugins/MirLua/src/mlua_script_loader.cpp
index b374007dce..13dc5bea99 100644
--- a/plugins/MirLua/src/mlua_script_loader.cpp
+++ b/plugins/MirLua/src/mlua_script_loader.cpp
@@ -13,20 +13,14 @@ void CLuaScriptLoader::LoadScript(const TCHAR *scriptDir, const TCHAR *file)
CMLuaScript *script = new CMLuaScript(L, path);
g_mLua->Scripts.insert(script);
- TCHAR buf[4096];
if (db_get_b(NULL, MODULE, _T2A(file), 1) == FALSE)
{
-
- mir_sntprintf(buf, _T("%s:PASS"), path);
- CallService(MS_NETLIB_LOGW, (WPARAM)hNetlib, (LPARAM)buf);
+ Log(_T("%s:PASS"), path);
return;
}
if (script->Load())
- {
- mir_sntprintf(buf, _T("%s:OK"), path);
- CallService(MS_NETLIB_LOGW, (WPARAM)hNetlib, (LPARAM)buf);
- }
+ Log(_T("%s:OK"), path);
}
void CLuaScriptLoader::LoadScripts()
@@ -34,9 +28,7 @@ void CLuaScriptLoader::LoadScripts()
TCHAR scriptDir[MAX_PATH];
FoldersGetCustomPathT(g_hScriptsFolder, scriptDir, _countof(scriptDir), VARST(MIRLUA_PATHT));
- TCHAR buf[4096];
- mir_sntprintf(buf, _T("Loading scripts from %s"), scriptDir);
- CallService(MS_NETLIB_LOGW, (WPARAM)hNetlib, (LPARAM)buf);
+ Log(_T("Loading scripts from %s"), scriptDir);
TCHAR searchMask[MAX_PATH];
mir_sntprintf(searchMask, _T("%s\\%s"), scriptDir, _T("*.lua"));