diff options
Diffstat (limited to 'src/coding.c')
| -rw-r--r-- | src/coding.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/coding.c b/src/coding.c index 44506476794..25ac0e9764c 100644 --- a/src/coding.c +++ b/src/coding.c | |||
| @@ -6613,8 +6613,8 @@ get_translation (Lisp_Object trans, int *buf, int *buf_end) | |||
| 6613 | { | 6613 | { |
| 6614 | Lisp_Object val = XCAR (trans); | 6614 | Lisp_Object val = XCAR (trans); |
| 6615 | Lisp_Object from = XCAR (val); | 6615 | Lisp_Object from = XCAR (val); |
| 6616 | int len = ASIZE (from); | 6616 | ptrdiff_t len = ASIZE (from); |
| 6617 | int i; | 6617 | ptrdiff_t i; |
| 6618 | 6618 | ||
| 6619 | for (i = 0; i < len; i++) | 6619 | for (i = 0; i < len; i++) |
| 6620 | { | 6620 | { |
| @@ -7132,7 +7132,7 @@ handle_composition_annotation (ptrdiff_t pos, ptrdiff_t limit, | |||
| 7132 | if (method != COMPOSITION_RELATIVE) | 7132 | if (method != COMPOSITION_RELATIVE) |
| 7133 | { | 7133 | { |
| 7134 | Lisp_Object components; | 7134 | Lisp_Object components; |
| 7135 | int len, i, i_byte; | 7135 | ptrdiff_t i, len, i_byte; |
| 7136 | 7136 | ||
| 7137 | components = COMPOSITION_COMPONENTS (prop); | 7137 | components = COMPOSITION_COMPONENTS (prop); |
| 7138 | if (VECTORP (components)) | 7138 | if (VECTORP (components)) |
| @@ -7303,7 +7303,7 @@ consume_chars (struct coding_system *coding, Lisp_Object translation_table, | |||
| 7303 | *buf++ = c; | 7303 | *buf++ = c; |
| 7304 | else | 7304 | else |
| 7305 | { | 7305 | { |
| 7306 | int from_nchars = 1, to_nchars = 1; | 7306 | ptrdiff_t from_nchars = 1, to_nchars = 1; |
| 7307 | int *lookup_buf_end; | 7307 | int *lookup_buf_end; |
| 7308 | const unsigned char *p = src; | 7308 | const unsigned char *p = src; |
| 7309 | int i; | 7309 | int i; |
| @@ -7324,7 +7324,7 @@ consume_chars (struct coding_system *coding, Lisp_Object translation_table, | |||
| 7324 | else | 7324 | else |
| 7325 | { | 7325 | { |
| 7326 | to_nchars = ASIZE (trans); | 7326 | to_nchars = ASIZE (trans); |
| 7327 | if (buf + to_nchars > buf_end) | 7327 | if (buf_end - buf < to_nchars) |
| 7328 | break; | 7328 | break; |
| 7329 | c = XINT (AREF (trans, 0)); | 7329 | c = XINT (AREF (trans, 0)); |
| 7330 | } | 7330 | } |