diff Log.cpp @ 1566:1e5086f7d401

undoing 1481
author Grumpy7
date Sun, 08 Sep 2013 04:11:10 +0200
parents 0356a84be1cf
children 56cc81b1ed49
line wrap: on
line diff
--- a/Log.cpp	Sun Sep 08 04:10:22 2013 +0200
+++ b/Log.cpp	Sun Sep 08 04:11:10 2013 +0200
@@ -19,14 +19,16 @@
     return;
 
   va_list args;
+  wchar_t pMsg[8192];
 
   va_start(args, pFormat);
-  vwprintf_s(pFormat, args);
+  vswprintf_s(pMsg, 8192, pFormat, args);
   va_end(args);
-  puts("\r\n");
 
+  DWORD w;
+  WriteConsole(hStdOut, pMsg, lstrlenW(pMsg), &w, nullptr);
+  WriteConsole(hStdOut, L"\r\n", 2, &w, nullptr);
 }
-
 //----- (004BE386) --------------------------------------------------------
 void __fastcall log_error(const char *pMessage)
 {