--- code/trunk/pcre_dfa_exec.c 2009/03/08 15:11:02 382 +++ code/trunk/pcre_dfa_exec.c 2009/03/08 15:26:59 383 @@ -3,10 +3,11 @@ *************************************************/ /* PCRE is a library of functions to support regular expressions whose syntax -and semantics are as close as possible to those of the Perl 5 language. +and semantics are as close as possible to those of the Perl 5 language (but see +below for why this module is different). Written by Philip Hazel - Copyright (c) 1997-2008 University of Cambridge + Copyright (c) 1997-2009 University of Cambridge ----------------------------------------------------------------------------- Redistribution and use in source and binary forms, with or without @@ -757,7 +758,7 @@ if ((md->moptions & PCRE_NOTEOL) == 0) { if (clen == 0 || - (IS_NEWLINE(ptr) && + ((md->poptions & PCRE_DOLLAR_ENDONLY) == 0 && IS_NEWLINE(ptr) && ((ims & PCRE_MULTILINE) != 0 || ptr == end_subject - md->nllen) )) { ADD_ACTIVE(state_offset + 1, 0); }