[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] /srv/bzr/emacs/trunk r112371: coding.c (decode_coding_iso_
From: |
K. Handa |
Subject: |
[Emacs-diffs] /srv/bzr/emacs/trunk r112371: coding.c (decode_coding_iso_2022): When an invalid escape sequence is encountered, reset the invocation and designation status to the safest one. |
Date: |
Thu, 25 Apr 2013 00:11:45 +0900 |
User-agent: |
Bazaar (2.5.0) |
------------------------------------------------------------
revno: 112371 [merge]
committer: K. Handa <address@hidden>
branch nick: trunk
timestamp: Thu 2013-04-25 00:11:45 +0900
message:
coding.c (decode_coding_iso_2022): When an invalid escape sequence is
encountered, reset the invocation and designation status to the safest one.
modified:
src/ChangeLog
src/coding.c
=== modified file 'src/ChangeLog'
--- a/src/ChangeLog 2013-04-22 05:18:30 +0000
+++ b/src/ChangeLog 2013-04-24 15:09:49 +0000
@@ -1,3 +1,9 @@
+2013-04-24 Kenichi Handa <address@hidden>
+
+ * coding.c (decode_coding_iso_2022): When an invalid escape
+ sequence is encountered, reset the invocation and designation
+ status to the safest one.
+
2013-04-22 Paul Eggert <address@hidden>
* Makefile.in (bootstrap-clean): Remove stamp-h1 too.
=== modified file 'src/coding.c'
--- a/src/coding.c 2013-04-06 07:33:18 +0000
+++ b/src/coding.c 2013-04-24 15:09:49 +0000
@@ -3887,6 +3887,14 @@
*charbuf++ = c < 0 ? -c : ASCII_BYTE_P (c) ? c : BYTE8_TO_CHAR (c);
char_offset++;
coding->errors++;
+ /* Reset the invocation and designation status to the safest
+ one; i.e. designate ASCII to the graphic register 0, and
+ invoke that register to the graphic plane 0. This typically
+ helps the case that an designation sequence for ASCII "ESC (
+ B" is somehow broken (e.g. broken by a newline). */
+ CODING_ISO_INVOCATION (coding, 0) = 0;
+ CODING_ISO_DESIGNATION (coding, 0) = charset_ascii;
+ charset_id_0 = charset_ascii;
continue;
break_loop:
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] /srv/bzr/emacs/trunk r112371: coding.c (decode_coding_iso_2022): When an invalid escape sequence is encountered, reset the invocation and designation status to the safest one.,
K. Handa <=