changeset 91887:507af35dcead

(Finternal_char_font): Fix compilation warning.
author Glenn Morris <rgm@gnu.org>
date Sat, 16 Feb 2008 22:32:49 +0000
parents a6f6f87e8b09
children f36760c61ee4
files src/fontset.c
diffstat 1 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/fontset.c	Sat Feb 16 22:21:45 2008 +0000
+++ b/src/fontset.c	Sat Feb 16 22:32:49 2008 +0000
@@ -2065,10 +2065,13 @@
 	  struct font *font = XSAVE_VALUE (font_object)->pointer;
 	  unsigned code = font->driver->encode_char (font, c);
 	  Lisp_Object fontname = font_get_name (font_object);
+	  /* Assignment to EMACS_INT stops GCC whining about limited range
+	     of data type.  */
+	  EMACS_INT cod = code;
 
 	  if (code == FONT_INVALID_CODE)
 	    return Qnil;
-	  if (code <= MOST_POSITIVE_FIXNUM)
+	  if (cod <= MOST_POSITIVE_FIXNUM)
 	    return Fcons (fontname, make_number (code));
 	  return Fcons (fontname, Fcons (make_number (code >> 16),
 					 make_number (code & 0xFFFF)));