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

Diff of /code/trunk/pcre_exec.c

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

revision 149 by ph10, Mon Apr 16 15:28:08 2007 UTC revision 150 by ph10, Tue Apr 17 08:22:40 2007 UTC
# Line 3840  switch ((((options & PCRE_NEWLINE_BITS) Line 3840  switch ((((options & PCRE_NEWLINE_BITS)
3840    case PCRE_NEWLINE_CR+    case PCRE_NEWLINE_CR+
3841         PCRE_NEWLINE_LF: newline = ('\r' << 8) | '\n'; break;         PCRE_NEWLINE_LF: newline = ('\r' << 8) | '\n'; break;
3842    case PCRE_NEWLINE_ANY: newline = -1; break;    case PCRE_NEWLINE_ANY: newline = -1; break;
3843    case PCRE_NEWLINE_ANYCRLF: newline = -2; break;    case PCRE_NEWLINE_ANYCRLF: newline = -2; break;
3844    default: return PCRE_ERROR_BADNEWLINE;    default: return PCRE_ERROR_BADNEWLINE;
3845    }    }
3846    
# Line 4148  for(;;) Line 4148  for(;;)
4148    
4149    if (anchored || start_match > end_subject) break;    if (anchored || start_match > end_subject) break;
4150    
4151    /* If we have just passed a CR and the newline option is CRLF or ANY or    /* If we have just passed a CR and the newline option is CRLF or ANY or
4152    ANYCRLF, and we are now at a LF, advance the match position by one more    ANYCRLF, and we are now at a LF, advance the match position by one more
4153    character. */    character. */
4154    
4155    if (start_match[-1] == '\r' &&    if (start_match[-1] == '\r' &&
4156         (md->nltype == NLTYPE_ANY ||         (md->nltype == NLTYPE_ANY ||
4157          md->nltype == NLTYPE_ANYCRLF ||          md->nltype == NLTYPE_ANYCRLF ||
4158          md->nllen == 2) &&          md->nllen == 2) &&
4159         start_match < end_subject &&         start_match < end_subject &&
4160         *start_match == '\n')         *start_match == '\n')

Legend:
Removed from v.149  
changed lines
  Added in v.150

webmaster@exim.org
ViewVC Help
Powered by ViewVC 1.1.12