From fa0853e16847e18e75a182949879b3a090a2580d Mon Sep 17 00:00:00 2001 From: Corinna Vinschen Date: Thu, 26 Mar 2009 10:26:57 +0000 Subject: [PATCH] * strfuncs.cc (__set_charset_from_codepage): Revert to translating codepage 936 to "GBK". --- winsup/cygwin/ChangeLog | 5 +++++ winsup/cygwin/strfuncs.cc | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index ed134d806..8e3470e38 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,3 +1,8 @@ +2009-03-26 Corinna Vinschen + + * strfuncs.cc (__set_charset_from_codepage): Revert to translating + codepage 936 to "GBK". + 2009-03-25 Corinna Vinschen * strfuncs.cc (sys_wcstombs): Don't convert ASCII SO into two diff --git a/winsup/cygwin/strfuncs.cc b/winsup/cygwin/strfuncs.cc index 03e14c015..bb3682225 100644 --- a/winsup/cygwin/strfuncs.cc +++ b/winsup/cygwin/strfuncs.cc @@ -28,7 +28,7 @@ details. */ implementation of the base functions for the conversion using the MulitByteToWideChar/WideCharToMultiByte functions. */ -/* GB2312, eucKR, and Big5 conversions are not available so far in newlib. */ +/* GBK, eucKR, and Big5 conversions are not available so far in newlib. */ static int __db_wctomb (struct _reent *r, char *s, wchar_t wchar, UINT cp) @@ -253,7 +253,7 @@ __set_charset_from_codepage (UINT cp, char *charset) strcpy (charset, "SJIS"); return __sjis_mbtowc; case 936: - strcpy (charset, "GB2312"); + strcpy (charset, "GBK"); return __gbk_mbtowc; case 949: case 51949: