forked from mirrors/0ad
Convert debug_printf to take UTF-8 strings instead of wchar_t.
This fixes the problem where passing a non-ASCII string to debug_printf(L"%hs", s) caused vswprintf_s to fail on Linux (because it doesn't know what encoding the char* is meant to have). Now debug messages will remain as UTF-8 until they reach the OS. Fixes #3021. This was SVN commit r16332.
This commit is contained in:
@@ -612,7 +612,7 @@ void SetCameraTarget(ScriptInterface::CxPrivate* UNUSED(pCxPrivate), float x, fl
|
||||
// Useful for testing the crashlog/stack trace code.
|
||||
int Crash(ScriptInterface::CxPrivate* UNUSED(pCxPrivate))
|
||||
{
|
||||
debug_printf(L"Crashing at user's request.\n");
|
||||
debug_printf("Crashing at user's request.\n");
|
||||
return *(volatile int*)0;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user