summaryrefslogtreecommitdiff
path: root/src/character.c
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2011-07-19 14:39:36 -0700
committerPaul Eggert <eggert@cs.ucla.edu>2011-07-19 14:39:36 -0700
commitebfa62c01481332072f519581aaf4d8d7da49e68 (patch)
treec62f6a866f44165112999f66f5ca7e5f30dc2af3 /src/character.c
parent63cf7836ae7616ce91d7eeaeac997d71609e191b (diff)
downloademacs-ebfa62c01481332072f519581aaf4d8d7da49e68.tar.gz
Use ptrdiff_t for composition IDs.
* character.c (lisp_string_width): * composite.c (composition_table_size, n_compositions) (get_composition_id, composition_gstring_from_id): * dispextern.h (struct glyph_string.cmp_id, struct composition_it.id): * xdisp.c (BUILD_COMPOSITE_GLYPH_STRING): * window.c (Frecenter): Use ptrdiff_t, not int, for composition IDs. * composite.c (get_composition_id): Check for integer overflow. * composite.h: Adjust prototypes to match the above changes.
Diffstat (limited to 'src/character.c')
-rw-r--r--src/character.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/character.c b/src/character.c
index c2f23e0d8ec..5e2eccf54db 100644
--- a/src/character.c
+++ b/src/character.c
@@ -423,7 +423,7 @@ lisp_string_width (Lisp_Object string, EMACS_INT precision,
{
EMACS_INT chars, bytes, thiswidth;
Lisp_Object val;
- int cmp_id;
+ ptrdiff_t cmp_id;
EMACS_INT ignore, end;
if (find_composition (i, -1, &ignore, &end, &val, string)