From 0ac8f59f0ca73e3d2530676e6ea3f8669d10eaed Mon Sep 17 00:00:00 2001 From: Vitaly Lipatov Date: Fri, 2 Apr 2010 20:59:36 +0400 Subject: [1/2] libs/wine: Fix debug output to use utf8 encoding. Content-Type: text/plain; charset=UTF-8 --- libs/wine/debug.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/libs/wine/debug.c b/libs/wine/debug.c index 6d38523c5f..36ca5ba511 100644 --- a/libs/wine/debug.c +++ b/libs/wine/debug.c @@ -32,6 +32,7 @@ #include "wine/debug.h" #include "wine/library.h" +#include "wine/unicode.h" #if defined(__MINGW32__) || defined(_MSC_VER) WINE_DECLARE_DEBUG_CHANNEL(tid); @@ -398,9 +399,8 @@ static const char *default_dbgstr_wn( const WCHAR *str, int n ) *dst++ = c; else { - *dst++ = '\\'; - sprintf(dst,"%04x",c); - dst+=4; + /* eterhack: code debug output to UTF-8 encoding */ + dst += wine_utf8_wcstombs(0, &c, 1, dst, 4); } } } -- 2.13.3