diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/debug.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/debug.cpp b/src/debug.cpp index d4d547c88..f8f3f0ad5 100644 --- a/src/debug.cpp +++ b/src/debug.cpp @@ -17,6 +17,10 @@ #include "fileio_func.h" #include "settings_type.h" +#if defined(WIN32) || defined(WIN64) +#include "os/windows/win32.h" +#endif + #include <time.h> #if defined(ENABLE_NETWORK) @@ -136,7 +140,9 @@ static void debug_print(const char *dbg, const char *buf) char buffer[512]; seprintf(buffer, lastof(buffer), "%sdbg: [%s] %s\n", GetLogPrefix(), dbg, buf); #if defined(WIN32) || defined(WIN64) - _fputts(OTTD2FS(buffer, true), stderr); + TCHAR system_buf[512]; + convert_to_fs(buffer, system_buf, lengthof(system_buf), true); + _fputts(system_buf, stderr); #else fputs(buffer, stderr); #endif |