diff options
| author | Kenichi Handa | 1998-05-01 04:15:48 +0000 |
|---|---|---|
| committer | Kenichi Handa | 1998-05-01 04:15:48 +0000 |
| commit | 49cb52b45cc936795fdfab8a19d22b4b44cecf03 (patch) | |
| tree | 023e22004d4f5888e778a65b7deb91850e226558 /src | |
| parent | 4eea26a9879a33e7161d00de1d7d367b3148e230 (diff) | |
| download | emacs-49cb52b45cc936795fdfab8a19d22b4b44cecf03.tar.gz emacs-49cb52b45cc936795fdfab8a19d22b4b44cecf03.zip | |
(encode_coding_iso2022): If encoding a last block,
reset graphic planes and registers.
Diffstat (limited to 'src')
| -rw-r--r-- | src/coding.c | 19 |
1 files changed, 8 insertions, 11 deletions
diff --git a/src/coding.c b/src/coding.c index f30942e3227..75ef204326d 100644 --- a/src/coding.c +++ b/src/coding.c | |||
| @@ -1946,17 +1946,14 @@ encode_coding_iso2022 (coding, source, destination, src_bytes, dst_bytes) | |||
| 1946 | break; | 1946 | break; |
| 1947 | } | 1947 | } |
| 1948 | 1948 | ||
| 1949 | if (src < src_end) | 1949 | if (src < src_end && result == CODING_FINISH_NORMAL) |
| 1950 | { | 1950 | result = CODING_FINISH_INSUFFICIENT_DST; |
| 1951 | if (result == CODING_FINISH_NORMAL) | 1951 | |
| 1952 | result = CODING_FINISH_INSUFFICIENT_DST; | 1952 | /* If this is the last block of the text to be encoded, we must |
| 1953 | else | 1953 | reset graphic planes and registers to the initial state, and |
| 1954 | /* If this is the last block of the text to be encoded, we | 1954 | flush out the carryover if any. */ |
| 1955 | must reset graphic planes and registers to the initial | 1955 | if (coding->mode & CODING_MODE_LAST_BLOCK) |
| 1956 | state, and flush out the carryover if any. */ | 1956 | ENCODE_RESET_PLANE_AND_REGISTER; |
| 1957 | if (coding->mode & CODING_MODE_LAST_BLOCK) | ||
| 1958 | ENCODE_RESET_PLANE_AND_REGISTER; | ||
| 1959 | } | ||
| 1960 | 1957 | ||
| 1961 | coding->consumed = src - source; | 1958 | coding->consumed = src - source; |
| 1962 | coding->produced = coding->produced_char = dst - destination; | 1959 | coding->produced = coding->produced_char = dst - destination; |