summaryrefslogtreecommitdiffstats
path: root/lib/libc/locale/setrunelocale.c
diff options
context:
space:
mode:
authordavidxu <davidxu@FreeBSD.org>2003-11-05 22:52:51 +0000
committerdavidxu <davidxu@FreeBSD.org>2003-11-05 22:52:51 +0000
commita6e1effefa802ad31038716500a89beb4a362186 (patch)
tree1411888c72024985a18eab202fc61b7bc0edf19f /lib/libc/locale/setrunelocale.c
parent13c2e3cf4f594cc57f94a1358e82743968558142 (diff)
downloadFreeBSD-src-a6e1effefa802ad31038716500a89beb4a362186.zip
FreeBSD-src-a6e1effefa802ad31038716500a89beb4a362186.tar.gz
Add gb2312 encoding.
Diffstat (limited to 'lib/libc/locale/setrunelocale.c')
-rw-r--r--lib/libc/locale/setrunelocale.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/libc/locale/setrunelocale.c b/lib/libc/locale/setrunelocale.c
index 0037f9c..43b759a 100644
--- a/lib/libc/locale/setrunelocale.c
+++ b/lib/libc/locale/setrunelocale.c
@@ -56,6 +56,7 @@ extern int _UTF2_init(_RuneLocale *);
extern int _UTF8_init(_RuneLocale *);
extern int _EUC_init(_RuneLocale *);
extern int _GB18030_init(_RuneLocale *);
+extern int _GB2312_init(_RuneLocale *);
extern int _GBK_init(_RuneLocale *);
extern int _BIG5_init(_RuneLocale *);
extern int _MSKanji_init(_RuneLocale *);
@@ -157,6 +158,8 @@ __setrunelocale(const char *encoding)
ret = _EUC_init(rl);
else if (strcmp(rl->encoding, "GB18030") == 0)
ret = _GB18030_init(rl);
+ else if (strcmp(rl->encoding, "GB2312") == 0)
+ ret = _GB2312_init(rl);
else if (strcmp(rl->encoding, "GBK") == 0)
ret = _GBK_init(rl);
else if (strcmp(rl->encoding, "BIG5") == 0)
OpenPOWER on IntegriCloud