mirror of
https://github.com/chibicitiberiu/rainmeter-studio.git
synced 2024-02-24 04:33:31 +00:00
Fixed: Now uses buffer strictly in DebugLog/LuaLog.
This commit is contained in:
parent
8c169e4d21
commit
e2d9a6cc71
@ -605,7 +605,7 @@ void DebugLog(const WCHAR* format, ... )
|
|||||||
WCHAR buffer[4096];
|
WCHAR buffer[4096];
|
||||||
va_list args;
|
va_list args;
|
||||||
va_start( args, format );
|
va_start( args, format );
|
||||||
_vsnwprintf( buffer, 4096, format, args );
|
_vsnwprintf_s( buffer, 4096, _TRUNCATE, format, args );
|
||||||
LSLog(LOG_DEBUG, L"Rainmeter", buffer);
|
LSLog(LOG_DEBUG, L"Rainmeter", buffer);
|
||||||
va_end(args);
|
va_end(args);
|
||||||
}
|
}
|
||||||
|
@ -59,7 +59,7 @@ void LuaManager::LuaLog(const char* format, ... )
|
|||||||
va_list args;
|
va_list args;
|
||||||
va_start( args, format );
|
va_start( args, format );
|
||||||
|
|
||||||
_vsnprintf(buffer, 4096, format, args );
|
_vsnprintf_s(buffer, 4096, _TRUNCATE, format, args );
|
||||||
|
|
||||||
#ifndef _DEBUG
|
#ifndef _DEBUG
|
||||||
// Forcing output to the Debug Output window!
|
// Forcing output to the Debug Output window!
|
||||||
@ -69,6 +69,6 @@ void LuaManager::LuaLog(const char* format, ... )
|
|||||||
|
|
||||||
std::wstring str = ConvertToWide(buffer);
|
std::wstring str = ConvertToWide(buffer);
|
||||||
|
|
||||||
LSLog(3,L"Lua", str.c_str());
|
LSLog(LOG_NOTICE, L"Lua", str.c_str());
|
||||||
va_end(args);
|
va_end(args);
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user