Sascha Schumann
23b9300fd1
more tsrm cleanup
2001-08-06 03:50:52 +00:00
Andrei Zmievski
8fca87adb5
Updated to match TSRM changes.
2001-07-30 15:41:11 +00:00
Zeev Suraski
c43806f415
Zend compatibility patch
2001-07-30 08:24:42 +00:00
Zeev Suraski
b0224d51da
Zend compatibility patch
2001-07-30 05:36:18 +00:00
Zeev Suraski
1c25b8dd53
Avoid TSRMLS_FETCH()'s, and clean up a bit of stale extern's and layout on the way
2001-07-30 01:56:43 +00:00
Zeev Suraski
d87cc976e1
Redesigned thread safety mechanism - nua nua
2001-07-28 11:36:37 +00:00
Zeev Suraski
fe6f8712a4
- Get rid of ELS_*(), and use TSRMLS_*() instead.
...
- Move to the new ts_allocate_id() API
This patch is *bound* to break some files, as I must have had typos somewhere.
If you use any uncommon extension, please try to build it...
2001-07-27 10:16:41 +00:00
Rui Hirokawa
86ae8add13
added an option to support utf-8 in pcre.
2001-07-13 03:37:18 +00:00
Rasmus Lerdorf
81e2cf03ac
Fix folding and clean up some extensions
2001-06-06 13:06:12 +00:00
Rasmus Lerdorf
25c3a3a39d
vim-6 does folding - clean up a bunch of missing folding tags plus
...
some misguided RINIT and RSHUTDOWN calls in a few fringe extensions
2001-06-05 13:12:10 +00:00
Stig Bakken
1beda9ee1e
* include "config.h" if HAVE_CONFIG_H is defined (for standalone dso build)
2001-05-24 10:07:29 +00:00
Andrei Zmievski
e1f671fb5c
Properly free callback_name only when necessary.
2001-05-20 01:21:44 +00:00
Andrei Zmievski
58f7df0ae4
Revert previous commit - callback_name does need to be checked because
...
it is set conditional on is_callable_replace.
2001-05-15 18:00:35 +00:00
Andrei Zmievski
eba50153ef
No need for check since callback_name is always filled in.
2001-05-14 12:58:48 +00:00
Wez Furlong
340c56e5c7
Fixed leak.
2001-05-12 00:45:55 +00:00
Andrei Zmievski
0eecec7773
@- Fixed a bug in preg_split() that would incorrectly limit the number of
...
@ results when used along with PREG_SPLIT_NO_EMPTY flag. (Andrei)
- Fixed a bug in preg_split() that would incorrectly limit the number of
results when used along with PREG_SPLIT_NO_EMPTY flag. (Andrei)
- Also made limit = -1 when limit = 0, to emulate Perl.
2001-05-04 16:43:53 +00:00
Sascha Schumann
c44da99842
Fix freeing of a NULL pointer
2001-04-22 17:20:03 +00:00
Andrei Zmievski
1a1018452c
@- Fixed a bug with /e modifier in preg_replace(), that would not correctly
...
@ replace two-digit references if single digit references were present
@ before them. This fixed bug #10218 . (Andrei)
2001-04-16 04:56:31 +00:00
Frank M. Kromann
f49d04fb12
Fixing compiler warning on win32
2001-03-13 16:39:47 +00:00
Andrei Zmievski
285ec0ca2c
@- IMPORTANT: removed /F modifier handling from preg_replace(). Instead
...
@ one should use new preg_replace_callback() function. (Andrei)
2001-03-13 05:24:03 +00:00
Andrei Zmievski
d73ef12429
@- Added array_reduce(), which allows iterative reduction of an array
...
@ to a single value via a callback function. (Andrei)
- Added array_reduce(), which allows iterative reduction of an array
to a single value via a callback function.
- Fixed usage of zend_is_callable() in PCRE.
2001-03-12 03:06:53 +00:00
Andi Gutmans
eb6ba01d1c
- Fix copyright notices with 2001
2001-02-26 06:11:02 +00:00
Andrei Zmievski
51c535f510
Move todo items.
2001-02-08 04:55:49 +00:00
Andrei Zmievski
56d3b036ec
Adding delimiter capturing functionality.
...
As far as NEWS, compilation fixed don't belong here.
2001-02-03 04:53:49 +00:00
Andrei Zmievski
898baa8b54
No need for CLS_FETCH().
2001-02-01 15:25:53 +00:00
Sascha Schumann
23ddeac9a5
Fix broken ZTS build
2001-02-01 15:24:17 +00:00
Andrei Zmievski
0651b4ff16
Modified /F handling to allow calling object methods.
2001-02-01 05:04:58 +00:00
Andrei Zmievski
b56006b5b2
If we can't call custom replacement function, don't change the subject
...
string.
2001-01-22 22:05:04 +00:00
Andrei Zmievski
5afcfc4498
Don't need to check for out-of-memory condition.
2001-01-22 19:42:29 +00:00
Andrei Zmievski
5068444dfe
Z-ify the source.
2001-01-22 19:29:44 +00:00
Andrei Zmievski
34f5c0c36d
Fix argument check (bug #8421 ).
2000-12-27 13:59:40 +00:00
Andrei Zmievski
a1614b8411
(PHP preg_replace) Fix to allow proper escaping of captured subpattern
...
references in the replacement string.
(PHP array_sum) Check that argument is an array.
2000-12-22 16:31:42 +00:00
Zeev Suraski
aa6d2ac5d0
Heads up people!
...
Updated the get_current_key() API - the relevant authors, please take
a look at the updated code and make sure it's ok...
2000-12-22 12:57:09 +00:00
Sascha Schumann
1626ba7ee9
Oh man, gcc's logic is really flawed
2000-11-27 13:28:26 +00:00
Sascha Schumann
aa6a62d96d
Kill a warning (code is correct)
2000-11-27 13:13:25 +00:00
Andrei Zmievski
def5059f44
Fix the arg array size.
2000-11-24 00:12:19 +00:00
Andrei Zmievski
0af5c36d94
This submission introduces two features.
...
The first one is support for Perl-style matching regexp delimiters, i.e.
using <[{( and )}]> to delimit the regular expressions.
The second one is a new 'F' modifier that allows you to specify a function name
in the replacement argument to preg_replace(). This function will be called
when the replacement needs to be made. It is passed an array of full matched
pattern and captured subpatterns and it is expected to return a string that
will be used for replacement. 'e' and 'F' modifiers cannot be used together.
@- Implemented support for Perl-style matching regexp delimiters in PCRE.
@ You can use <{[( and )]}> to delimit your expressions now. (Andrei)
@- Introduced new 'F' modifier in PCRE that lets you specify a function
@ name in the replacement argument to preg_replace() that will be called
@ at run-time to provide the replacement string. It is passed an array of
@ matched pattern and subpatterns. (Andrei)
2000-11-23 17:25:13 +00:00
Andrei Zmievski
3625a729a7
- Modified preg_replace() to take Perl-style $1 backreferences in addition
...
to \\n ones.
- Modified preg_grep() to always return the results with the keys
from the original array.
2000-11-15 05:09:55 +00:00
Andrei Zmievski
468068705f
@- Modified preg_replace() to ignore backreferences that refer to
...
@ non-existing subpatterns. (Andrei)
2000-11-13 19:49:41 +00:00
Andrei Zmievski
b111463f4c
Fixed bug #6740 .
...
I happen to think that this is php_addslashes() problem, not PCRE's.
When 0 is passed for the length of the string to php_addslashes() it
assumes that we want to process the whole string and happily runs
strlen() on it. That is bad. It should respect the length and return
an empty string if it's 0.
2000-09-14 15:44:36 +00:00
Zeev Suraski
6c3d7449e1
- Made eval() and several other runtime-evaluated code portions report the
...
nature and location of errors more accurately (Stas)
2000-09-12 20:48:33 +00:00
Andrei Zmievski
4df36948c8
@- Fixed a bug in preg_replace() that would truncate subject string if the
...
@ first argument was en empty array. (Andrei)
This fixes bug #6346 , that would truncate subject string if the
first argument was en empty array.
2000-08-25 13:51:07 +00:00
Andrei Zmievski
d7c43de3ce
@- Fixed a bug that did not respect limit parameter in preg_replace() when
...
@ using /e modifier. (Andrei)
2000-08-24 13:23:13 +00:00
Andrei Zmievski
4f96d15f33
Reverting the pemalloc -> malloc change until we figure out why it breaks.
2000-08-17 19:01:28 +00:00
Andrei Zmievski
ba0e3f2145
No need to have persistent allocation.
2000-08-17 16:09:00 +00:00
Andrei Zmievski
9de5b9e04a
# There you go, Wico.
...
Fix bug $5676.
@- Fixed preg_replace() to automatically escape quotes in matched
@ strings when using /e modifier. (Andrei)
2000-07-20 15:27:16 +00:00
Andrei Zmievski
1ca7f07d1a
Typo.
2000-06-30 19:40:42 +00:00
Andrei Zmievski
29e8e565c6
@- Added an optional parameter to preg_replace() that can be used to
...
@ specify how many replacements to make. (Andrei)
2000-06-28 20:07:26 +00:00
Andrei Zmievski
7ef638aa30
@- Upgraded PCRE to version 3.2 and fixed a bug when anchored pattern
...
@ matched an empty string. (Andrei)
2000-06-12 19:55:58 +00:00
Andrei Zmievski
f20194149f
One more place.
2000-06-10 19:44:34 +00:00