OSDN Git Service

Add setlocale function call for support multibyte character in main-gcu
authorhabu <habu@0568b783-4c39-0410-ac80-bf13821ea2a2>
Sun, 17 Feb 2013 13:16:17 +0000 (13:16 +0000)
committerhabu <habu@0568b783-4c39-0410-ac80-bf13821ea2a2>
Sun, 17 Feb 2013 13:16:17 +0000 (13:16 +0000)
src/main-gcu.c

index a8f5bc4..41a4968 100644 (file)
@@ -254,6 +254,9 @@ static term_data data[MAX_TERM_DATA];
 #endif
 
 
+#include <locale.h>
+
+
 /*
  * XXX XXX Hack -- POSIX uses "O_NONBLOCK" instead of "O_NDELAY"
  *
@@ -1205,6 +1208,8 @@ errr init_gcu(int argc, char *argv[])
    (void)argv;
 
 
+   setlocale(LC_ALL, "");
+
 #ifdef USE_SOUND
 
    /* Build the "sound" path */