(decode_coding_iso_2022): Ignore ISO_CODE_SS2_7 (0x19)
authorKenichi Handa <handa@m17n.org>
Mon, 14 Dec 2009 01:20:29 +0000 (01:20 +0000)
committerKenichi Handa <handa@m17n.org>
Mon, 14 Dec 2009 01:20:29 +0000 (01:20 +0000)
in 8-bit encoding.

src/ChangeLog
src/coding.c

index a143e1d..352a723 100644 (file)
@@ -1,3 +1,8 @@
+2009-12-14  Kenichi Handa  <handa@m17n.org>
+
+       * coding.c (decode_coding_iso_2022): Ignore ISO_CODE_SS2_7 (0x19)
+       in 8-bit encoding.
+
 2009-12-13  Pat Thoyts <patthoyts@users.sourceforge.net> (tiny change)
 
        * xfns.c (x_create_tip_frame): Set the extended window manager hint for
index 1d838db..a161f5a 100644 (file)
@@ -3726,6 +3726,8 @@ decode_coding_iso_2022 (coding)
          continue;
 
        case ISO_single_shift_2_7:
+         if (! (CODING_ISO_FLAGS (coding) & CODING_ISO_FLAG_SEVEN_BITS))
+           goto invalid_code;
        case ISO_single_shift_2:
          if (! (CODING_ISO_FLAGS (coding) & CODING_ISO_FLAG_SINGLE_SHIFT))
            goto invalid_code;