From bc900b1118e1fc7b065b37e4d28aa7c998ce5a66 Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Sun, 26 Apr 1998 10:28:28 +0000 Subject: Update. 1998-04-26 Ulrich Drepper * iconvdata/gconv-modules: Add entry for ISO-2022-JP and ISO-2022-JP-2. --- iconvdata/gb2312.h | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'iconvdata/gb2312.h') diff --git a/iconvdata/gb2312.h b/iconvdata/gb2312.h index 3de274e06b..cde9375e84 100644 --- a/iconvdata/gb2312.h +++ b/iconvdata/gb2312.h @@ -23,6 +23,7 @@ #include #include +#include /* Conversion table. */ extern const uint16_t __gb2312_to_ucs[]; @@ -66,7 +67,7 @@ extern const char __gb2312_from_ucs4_tab8[][2]; extern const char __gb2312_from_ucs4_tab9[][2]; static inline size_t -ucs4_to_gb2312 (uint32_t wch, unsigned char **s, size_t avail) +ucs4_to_gb2312 (uint32_t wch, unsigned char *s, size_t avail) { unsigned int ch = (unsigned int) wch; char buf[2]; @@ -220,8 +221,8 @@ ucs4_to_gb2312 (uint32_t wch, unsigned char **s, size_t avail) if (avail < 2) return 0; - *(*s)++ = cp[0]; - *(*s)++ = cp[1]; + s[0] = cp[0]; + s[1] = cp[1]; return 2; } -- cgit v1.2.3