diff options
| author | Andrey Hristov <andrey@php.net> | 1999-05-29 19:38:50 +0000 |
|---|---|---|
| committer | Andrey Hristov <andrey@php.net> | 1999-05-29 19:38:50 +0000 |
| commit | 9c970e1910a9e7863eb92f0a8b2286a5aeb11b46 (patch) | |
| tree | 20cad25be706d053b60c02327a1eaadc8991d496 /ext/pcre/pcre.c | |
| parent | e058cccfc101b56ac49593106c775f12c3b4d726 (diff) | |
| download | php-git-9c970e1910a9e7863eb92f0a8b2286a5aeb11b46.tar.gz | |
Fixed PCRE so that global matching with patterns with \b works.
Diffstat (limited to 'ext/pcre/pcre.c')
| -rw-r--r-- | ext/pcre/pcre.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/ext/pcre/pcre.c b/ext/pcre/pcre.c index 30721b09e6..a36a2dce2c 100644 --- a/ext/pcre/pcre.c +++ b/ext/pcre/pcre.c @@ -29,8 +29,6 @@ /* $Id$ */ -/* Get PCRE library from ftp://ftp.cus.cam.ac.uk/pub/software/programs/pcre/ */ - #include "php.h" #if HAVE_PCRE @@ -381,7 +379,7 @@ void _pcre_match(INTERNAL_FUNCTION_PARAMETERS, int global) do { /* Execute the regular expression. */ count = pcre_exec(re, extra, &subject->value.str.val[subject_offset], - subject->value.str.len-subject_offset, + subject->value.str.len-subject_offset, subject->value.str.val, (subject_offset ? exoptions|PCRE_NOTBOL : exoptions), offsets, size_offsets, 0); @@ -548,7 +546,7 @@ char *_php_pcre_replace(char *regex, char *subject, char *replace) while (count >= 0) { /* Execute the regular expression. */ count = pcre_exec(re, extra, piece, - subject_end-piece, + subject_end-piece, subject, (piece==subject ? exoptions : exoptions|PCRE_NOTBOL), offsets, size_offsets, (piece == match)); @@ -796,7 +794,7 @@ PHP_FUNCTION(preg_split) /* Get next piece if no limit or limit not yet reached and something matched*/ while ((limit_val == -1 || limit_val > 0) && count >= 0) { count = pcre_exec(re, extra, &subject->value.str.val[last_offset], - subject->value.str.len-last_offset, + subject->value.str.len-last_offset, subject->value.str.val, (last_offset ? exoptions|PCRE_NOTBOL : exoptions), offsets, size_offsets, 0); |
