emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] emacs/src lread.c


From: Kenichi Handa
Subject: [Emacs-diffs] emacs/src lread.c
Date: Fri, 27 Feb 2009 00:48:03 +0000

CVSROOT:        /cvsroot/emacs
Module name:    emacs
Changes by:     Kenichi Handa <handa>   09/02/27 00:48:03

Modified files:
        src            : lread.c 

Log message:
        (read_escape): Signal an error for invalid \UXXXXXXXX.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/emacs/src/lread.c?cvsroot=emacs&r1=1.403&r2=1.404

Patches:
Index: lread.c
===================================================================
RCS file: /cvsroot/emacs/emacs/src/lread.c,v
retrieving revision 1.403
retrieving revision 1.404
diff -u -b -r1.403 -r1.404
--- lread.c     25 Feb 2009 12:47:24 -0000      1.403
+++ lread.c     27 Feb 2009 00:48:03 -0000      1.404
@@ -2205,7 +2205,7 @@
       /* A Unicode escape. We only permit them in strings and characters,
         not arbitrarily in the source code, as in some other languages.  */
       {
-       int i = 0;
+       unsigned int i = 0;
        int count = 0;
 
        while (++count <= unicode_hex_count)
@@ -2222,7 +2222,8 @@
                break;
              }
          }
-
+       if (i > 0x10FFFF)
+         error ("Non-Unicode character: 0x%x", i);
        return i;
       }
 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]