/[pcre]/code/trunk/pcre_dfa_exec.c
ViewVC logotype

Diff of /code/trunk/pcre_dfa_exec.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1320 by ph10, Wed May 1 16:39:35 2013 UTC revision 1334 by ph10, Wed May 15 16:53:18 2013 UTC
# Line 636  for (;;) Line 636  for (;;)
636      const pcre_uchar *code;      const pcre_uchar *code;
637      int state_offset = current_state->offset;      int state_offset = current_state->offset;
638      int codevalue, rrc;      int codevalue, rrc;
639      unsigned int count;      int count;
640    
641  #ifdef PCRE_DEBUG  #ifdef PCRE_DEBUG
642      printf ("%.*sProcessing state %d c=", rlevel*2-2, SP, state_offset);      printf ("%.*sProcessing state %d c=", rlevel*2-2, SP, state_offset);
# Line 1255  for (;;) Line 1255  for (;;)
1255                (d != OP_ANY || !IS_NEWLINE(ptr)) &&                (d != OP_ANY || !IS_NEWLINE(ptr)) &&
1256                ((ctypes[c] & toptable1[d]) ^ toptable2[d]) != 0))                ((ctypes[c] & toptable1[d]) ^ toptable2[d]) != 0))
1257            {            {
1258            if (++count >= GET2(code, 1))            if (++count >= (int)GET2(code, 1))
1259              { ADD_NEW(state_offset + 1 + IMM2_SIZE + 1, 0); }              { ADD_NEW(state_offset + 1 + IMM2_SIZE + 1, 0); }
1260            else            else
1261              { ADD_NEW(state_offset, count); }              { ADD_NEW(state_offset, count); }
# Line 1289  for (;;) Line 1289  for (;;)
1289              active_count--;           /* Remove non-match possibility */              active_count--;           /* Remove non-match possibility */
1290              next_active_state--;              next_active_state--;
1291              }              }
1292            if (++count >= GET2(code, 1))            if (++count >= (int)GET2(code, 1))
1293              { ADD_NEW(state_offset + 2 + IMM2_SIZE, 0); }              { ADD_NEW(state_offset + 2 + IMM2_SIZE, 0); }
1294            else            else
1295              { ADD_NEW(state_offset, count); }              { ADD_NEW(state_offset, count); }
# Line 1903  for (;;) Line 1903  for (;;)
1903              active_count--;           /* Remove non-match possibility */              active_count--;           /* Remove non-match possibility */
1904              next_active_state--;              next_active_state--;
1905              }              }
1906            if (++count >= GET2(code, 1))            if (++count >= (int)GET2(code, 1))
1907              { ADD_NEW(state_offset + 1 + IMM2_SIZE + 3, 0); }              { ADD_NEW(state_offset + 1 + IMM2_SIZE + 3, 0); }
1908            else            else
1909              { ADD_NEW(state_offset, count); }              { ADD_NEW(state_offset, count); }
# Line 1942  for (;;) Line 1942  for (;;)
1942            }            }
1943          if (nptr >= end_subject && (md->moptions & PCRE_PARTIAL_HARD) != 0)          if (nptr >= end_subject && (md->moptions & PCRE_PARTIAL_HARD) != 0)
1944              reset_could_continue = TRUE;              reset_could_continue = TRUE;
1945          if (++count >= GET2(code, 1))          if (++count >= (int)GET2(code, 1))
1946            { ADD_NEW_DATA(-(state_offset + 2 + IMM2_SIZE), 0, ncount); }            { ADD_NEW_DATA(-(state_offset + 2 + IMM2_SIZE), 0, ncount); }
1947          else          else
1948            { ADD_NEW_DATA(-state_offset, count, ncount); }            { ADD_NEW_DATA(-state_offset, count, ncount); }
# Line 1984  for (;;) Line 1984  for (;;)
1984              active_count--;           /* Remove non-match possibility */              active_count--;           /* Remove non-match possibility */
1985              next_active_state--;              next_active_state--;
1986              }              }
1987            if (++count >= GET2(code, 1))            if (++count >= (int)GET2(code, 1))
1988              { ADD_NEW_DATA(-(state_offset + 2 + IMM2_SIZE), 0, ncount); }              { ADD_NEW_DATA(-(state_offset + 2 + IMM2_SIZE), 0, ncount); }
1989            else            else
1990              { ADD_NEW_DATA(-state_offset, count, ncount); }              { ADD_NEW_DATA(-state_offset, count, ncount); }
# Line 2024  for (;;) Line 2024  for (;;)
2024              active_count--;           /* Remove non-match possibility */              active_count--;           /* Remove non-match possibility */
2025              next_active_state--;              next_active_state--;
2026              }              }
2027            if (++count >= GET2(code, 1))            if (++count >= (int)GET2(code, 1))
2028              { ADD_NEW_DATA(-(state_offset + 2 + IMM2_SIZE), 0, 0); }              { ADD_NEW_DATA(-(state_offset + 2 + IMM2_SIZE), 0, 0); }
2029            else            else
2030              { ADD_NEW_DATA(-state_offset, count, 0); }              { ADD_NEW_DATA(-state_offset, count, 0); }
# Line 2061  for (;;) Line 2061  for (;;)
2061              active_count--;           /* Remove non-match possibility */              active_count--;           /* Remove non-match possibility */
2062              next_active_state--;              next_active_state--;
2063              }              }
2064            if (++count >= GET2(code, 1))            if (++count >= (int)GET2(code, 1))
2065              { ADD_NEW_DATA(-(state_offset + 2 + IMM2_SIZE), 0, 0); }              { ADD_NEW_DATA(-(state_offset + 2 + IMM2_SIZE), 0, 0); }
2066            else            else
2067              { ADD_NEW_DATA(-state_offset, count, 0); }              { ADD_NEW_DATA(-state_offset, count, 0); }
# Line 2431  for (;;) Line 2431  for (;;)
2431            }            }
2432          if ((c == d || c == otherd) == (codevalue < OP_NOTSTAR))          if ((c == d || c == otherd) == (codevalue < OP_NOTSTAR))
2433            {            {
2434            if (++count >= GET2(code, 1))            if (++count >= (int)GET2(code, 1))
2435              { ADD_NEW(state_offset + dlen + 1 + IMM2_SIZE, 0); }              { ADD_NEW(state_offset + dlen + 1 + IMM2_SIZE, 0); }
2436            else            else
2437              { ADD_NEW(state_offset, count); }              { ADD_NEW(state_offset, count); }
# Line 2480  for (;;) Line 2480  for (;;)
2480              active_count--;             /* Remove non-match possibility */              active_count--;             /* Remove non-match possibility */
2481              next_active_state--;              next_active_state--;
2482              }              }
2483            if (++count >= GET2(code, 1))            if (++count >= (int)GET2(code, 1))
2484              { ADD_NEW(state_offset + dlen + 1 + IMM2_SIZE, 0); }              { ADD_NEW(state_offset + dlen + 1 + IMM2_SIZE, 0); }
2485            else            else
2486              { ADD_NEW(state_offset, count); }              { ADD_NEW(state_offset, count); }
# Line 2553  for (;;) Line 2553  for (;;)
2553            case OP_CRRANGE:            case OP_CRRANGE:
2554            case OP_CRMINRANGE:            case OP_CRMINRANGE:
2555            count = current_state->count;  /* Already matched */            count = current_state->count;  /* Already matched */
2556            if (count >= GET2(ecode, 1))            if (count >= (int)GET2(ecode, 1))
2557              { ADD_ACTIVE(next_state_offset + 1 + 2 * IMM2_SIZE, 0); }              { ADD_ACTIVE(next_state_offset + 1 + 2 * IMM2_SIZE, 0); }
2558            if (isinclass)            if (isinclass)
2559              {              {
2560              unsigned int max = GET2(ecode, 1 + IMM2_SIZE);              int max = (int)GET2(ecode, 1 + IMM2_SIZE);
2561              if (++count >= max && max != 0)   /* Max 0 => no limit */              if (++count >= max && max != 0)   /* Max 0 => no limit */
2562                { ADD_NEW(next_state_offset + 1 + 2 * IMM2_SIZE, 0); }                { ADD_NEW(next_state_offset + 1 + 2 * IMM2_SIZE, 0); }
2563              else              else

Legend:
Removed from v.1320  
changed lines
  Added in v.1334

  ViewVC Help
Powered by ViewVC 1.1.5