[Pcre-svn] [894] code/trunk/pcre_dfa_exec.c: Avoid compiler …

Top Page
Delete this message
Author: Subversion repository
Date:  
To: pcre-svn
Subject: [Pcre-svn] [894] code/trunk/pcre_dfa_exec.c: Avoid compiler warning when UTF not configured.
Revision: 894
          http://vcs.pcre.org/viewvc?view=rev&revision=894
Author:   ph10
Date:     2012-01-20 11:58:19 +0000 (Fri, 20 Jan 2012)


Log Message:
-----------
Avoid compiler warning when UTF not configured.

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


Modified: code/trunk/pcre_dfa_exec.c
===================================================================
--- code/trunk/pcre_dfa_exec.c    2012-01-19 17:15:11 UTC (rev 893)
+++ code/trunk/pcre_dfa_exec.c    2012-01-20 11:58:19 UTC (rev 894)
@@ -2690,10 +2690,10 @@
           {
           for (rc = rc*2 - 2; rc >= 0; rc -= 2)
             {
+            int charcount = local_offsets[rc+1] - local_offsets[rc];
+#ifdef SUPPORT_UTF
             const pcre_uchar *p = start_subject + local_offsets[rc];
             const pcre_uchar *pp = start_subject + local_offsets[rc+1];
-            int charcount = local_offsets[rc+1] - local_offsets[rc];
-#ifdef SUPPORT_UTF
             while (p < pp) if (NOT_FIRSTCHAR(*p++)) charcount--;
 #endif
             if (charcount > 0)