summaryrefslogtreecommitdiffstats
path: root/Modules/cjkcodecs/_iso2022_jp.c
diff options
context:
space:
mode:
Diffstat (limited to 'Modules/cjkcodecs/_iso2022_jp.c')
-rw-r--r--Modules/cjkcodecs/_iso2022_jp.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/Modules/cjkcodecs/_iso2022_jp.c b/Modules/cjkcodecs/_iso2022_jp.c
index d0b3b1f..486fe99 100644
--- a/Modules/cjkcodecs/_iso2022_jp.c
+++ b/Modules/cjkcodecs/_iso2022_jp.c
@@ -49,7 +49,7 @@ ENCODER(iso2022_jp)
if (c < 0x80) {
switch (STATE_GETG0(state)) {
case CHARSET_ASCII:
- WRITE1(c)
+ WRITE1((unsigned char)c)
NEXT(1, 1)
break;
case CHARSET_JISX0201_R:
@@ -61,7 +61,7 @@ ENCODER(iso2022_jp)
STATE_SETG0(state, CHARSET_ASCII)
code = c;
}
- WRITE1(code)
+ WRITE1((unsigned char)code)
NEXT(1, 1)
break;
}
@@ -77,7 +77,7 @@ ENCODER(iso2022_jp)
code = DBCINV;
JISX0201_R_ENCODE(c, code)
if (code != DBCINV) {
- WRITE1(code)
+ WRITE1((unsigned char)code)
NEXT(1, 1)
continue;
}
@@ -101,7 +101,7 @@ jisx0208encode: if (charset != CHARSET_JISX0208) {
else
return 1;
/* if (charset == CHARSET_JISX0201_R) : already checked */
- WRITE4(ESC, '(', 'J', code)
+ WRITE4(ESC, '(', 'J', (unsigned char)code)
STATE_SETG0(state, CHARSET_JISX0201_R)
NEXT(1, 4)
}