[Pcre-svn] [1077] code/trunk/pcre_compile.c: pcre32: compile…

Página superior
Eliminar este mensaje
Autor: Subversion repository
Fecha:  
A: pcre-svn
Asunto: [Pcre-svn] [1077] code/trunk/pcre_compile.c: pcre32: compile: Fix signed/ unsigned mismatch in compile_branch
Revision: 1077
          http://vcs.pcre.org/viewvc?view=rev&revision=1077
Author:   chpe
Date:     2012-10-16 16:54:57 +0100 (Tue, 16 Oct 2012)


Log Message:
-----------
pcre32: compile: Fix signed/unsigned mismatch in compile_branch

Modified Paths:
--------------
    code/trunk/pcre_compile.c


Modified: code/trunk/pcre_compile.c
===================================================================
--- code/trunk/pcre_compile.c    2012-10-16 15:54:54 UTC (rev 1076)
+++ code/trunk/pcre_compile.c    2012-10-16 15:54:57 UTC (rev 1077)
@@ -3783,7 +3783,7 @@
   int terminator;
   int mclength;
   int tempbracount;
-  int ec; // FIXMEchpe pcre_uint32
+  pcre_uint32 ec;
   pcre_uchar mcbuffer[8];


/* Get next character in the pattern */
@@ -4416,7 +4416,7 @@

       if (!inescq && ptr[1] == CHAR_MINUS)
         {
-        int d;
+        pcre_uint32 d;
         ptr += 2;
         while (*ptr == CHAR_BACKSLASH && ptr[1] == CHAR_E) ptr += 2;


@@ -5786,7 +5786,7 @@
         while (MAX_255(*ptr) && (cd->ctypes[*ptr] & ctype_word) != 0)
           {
           if (recno >= 0)
-            recno = (IS_DIGIT(*ptr))? recno * 10 + *ptr - CHAR_0 : -1;
+            recno = (IS_DIGIT(*ptr))? recno * 10 + (int)(*ptr - CHAR_0) : -1;
           ptr++;
           }
         namelen = (int)(ptr - name);