From 56adbe62a5c90ec0935d751fa311d41eb6d86a39 Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Thu, 2 Aug 2012 02:20:01 -0700 Subject: [PATCH] * xfaces.c: Don't assume buffer size fits in 'int'. --- src/ChangeLog | 2 ++ src/xfaces.c | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index f23865323c0..9ac301efed0 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,6 +1,8 @@ 2012-08-02 Paul Eggert * xfaces.c (face_at_buffer_position): Remove unused local. + (face_at_buffer_position, face_for_overlay_string): + Don't assume buffer size fits in 'int'. Use C99-style 'extern inline' if available. * buffer.h (BUFFER_INLINE): diff --git a/src/xfaces.c b/src/xfaces.c index e72670a1317..d6b9aae0909 100644 --- a/src/xfaces.c +++ b/src/xfaces.c @@ -6101,7 +6101,7 @@ face_at_buffer_position (struct window *w, ptrdiff_t pos, for (i = 0; i < noverlays; i++) { Lisp_Object oend; - int oendpos; + ptrdiff_t oendpos; prop = Foverlay_get (overlay_vec[i], propname); if (!NILP (prop)) @@ -6145,7 +6145,7 @@ face_for_overlay_string (struct window *w, ptrdiff_t pos, Lisp_Object attrs[LFACE_VECTOR_SIZE]; Lisp_Object prop, position; Lisp_Object frame; - int endpos; + ptrdiff_t endpos; Lisp_Object propname = mouse ? Qmouse_face : Qface; Lisp_Object limit1, end; struct face *default_face;