about summary refs log tree commit diff
path: root/iconvdata/iso-2022-cn-ext.c
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2008-01-09 20:03:58 +0000
committerUlrich Drepper <drepper@redhat.com>2008-01-09 20:03:58 +0000
commit4b1b449d1d4fda5658a3eb8378413aa224de0cf6 (patch)
tree9ab935ce8338639475e800500b66527d0ddfc03f /iconvdata/iso-2022-cn-ext.c
parent148e12ed122d75506937cdc8ab2654f8449f2061 (diff)
downloadglibc-4b1b449d1d4fda5658a3eb8378413aa224de0cf6.tar.gz
glibc-4b1b449d1d4fda5658a3eb8378413aa224de0cf6.tar.xz
glibc-4b1b449d1d4fda5658a3eb8378413aa224de0cf6.zip
008-01-08 Jakub Jelinek <jakub@redhat.com>
	* iconv/loop.c (UPDATE_PARAMS): Define to empty statement if not
	defined.
	(REINIT_PARAMS): Likewise.  Undefine before end of file.
	(STANDARD_TO_LOOP_ERR_HANDLER): Use UPDATE_PARAMS before calling
	transliteration hooks and REINIT_PARAMS afterwards.
	* iconvdata/iso-2022-jp.c (BODY): Use a separate variable for
	status.
	(REINIT_PARAMS): Define.
	* iconvdata/ibm1364.c (REINIT_PARAMS): Likewise.
	* iconvdata/ibm930.c (REINIT_PARAMS): Likewise.
	* iconvdata/ibm933.c (REINIT_PARAMS): Likewise.
	* iconvdata/ibm935.c (REINIT_PARAMS): Likewise.
	* iconvdata/ibm937.c (REINIT_PARAMS): Likewise.
	* iconvdata/ibm939.c (REINIT_PARAMS): Likewise.
	* iconvdata/iso-2022-cn.c (REINIT_PARAMS): Likewise.
	* iconvdata/iso-2022-cn-ext.c (REINIT_PARAMS): Likewise.
	* iconvdata/iso-2022-jp-3.c (REINIT_PARAMS): Likewise.
	* iconvdata/iso-2022-kr.c (REINIT_PARAMS): Likewise.
	* iconvdata/Makefile: Add rules to build and run tst-iconv7.c.
	* iconvdata/tst-iconv7.c: New test.
Diffstat (limited to 'iconvdata/iso-2022-cn-ext.c')
-rw-r--r--iconvdata/iso-2022-cn-ext.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/iconvdata/iso-2022-cn-ext.c b/iconvdata/iso-2022-cn-ext.c
index fd02d63592..3ffaf19881 100644
--- a/iconvdata/iso-2022-cn-ext.c
+++ b/iconvdata/iso-2022-cn-ext.c
@@ -1,5 +1,5 @@
 /* Conversion module for ISO-2022-CN-EXT.
-   Copyright (C) 2000-2002, 2004, 2007 Free Software Foundation, Inc.
+   Copyright (C) 2000-2002, 2004, 2007, 2008 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 2000.
 
@@ -648,6 +648,12 @@ enum
 #define EXTRA_LOOP_DECLS	, int *setp
 #define INIT_PARAMS		int set = (*setp >> 3) & CURRENT_MASK; \
 				int ann = (*setp >> 3) & ~CURRENT_MASK
+#define REINIT_PARAMS		do					      \
+				  {					      \
+				    set = (*setp >> 3) & CURRENT_MASK;	      \
+				    ann = (*setp >> 3) & ~CURRENT_MASK;	      \
+				  }					      \
+				while (0)
 #define UPDATE_PARAMS		*setp = (set | ann) << 3
 #define LOOP_NEED_FLAGS
 #include <iconv/loop.c>