summaryrefslogtreecommitdiff
path: root/ext/mbstring/php_mbregex.c
Commit message (Collapse)AuthorAgeFilesLines
* Fix typos in code commentsPeter Kokot2018-07-251-1/+1
|
* Remove unused Git attributes identPeter Kokot2018-07-251-3/+0
| | | | | | | | | | | | | | | The $Id$ keywords were used in Subversion where they can be substituted with filename, last revision number change, last changed date, and last user who changed it. In Git this functionality is different and can be done with Git attribute ident. These need to be defined manually for each file in the .gitattributes file and are afterwards replaced with 40-character hexadecimal blob object name which is based only on the particular file contents. This patch simplifies handling of $Id$ keywords by removing them since they are not used anymore.
* Add UPGRADING for mb_ereg changesNikita Popov2018-07-071-20/+14
| | | | Also some minor code cleanup.
* adds support for named subpatterns to `mb_ereg_replace`ju1ius2018-07-061-30/+135
| | | | | | | | | | Named subpatterns are now passed to `mb_ereg_replace_callback`. This commit also adds a subset of the oniguruma back-reference syntax for replacements: * `\k<name>` and `\k'name'` for named subpatterns. * `\k<n>` and `\k'n'` for numbered subpatterns These last two notations allow referencing numbered groups where n > 9.
* adds support for named captures to mb_ereg & mb_ereg_searchju1ius2018-07-061-0/+67
| | | | | | | `mb_ereg`, `mb_ereg_search_regs` & `mb_ereg_search_getregs` returned only numbered capturing groups. Now they return both numbered and named capturing groups. Fixes Bug #72704.
* Fixed incorrrecr zval_dtor() usage to replace value of argument passed by ↵Dmitry Stogov2018-07-051-1/+1
| | | | reference, that may lead to memory leaks.
* Replace legacy zval_dtor() by zval_ptr_dtor_nogc() or even more specialized ↵Dmitry Stogov2018-07-041-2/+2
| | | | | | | destructors. zval_dtor() doesn't make a lot of sense in PHP-7.* and it's used incorrectly in some places. Its occurances should be replaced by zval_ptr_dtor() or zval_ptr_dtor_nogc(), or even more specialized destructors.
* Remove code duplicationNikita Popov2018-06-201-12/+8
| | | | And fix indentation
* Rework datatypes wrt warningsAnatol Belski2018-03-201-13/+15
|
* Merge branch 'PHP-7.2'Christoph M. Becker2018-03-201-1/+1
|\ | | | | | | | | * PHP-7.2: Fix #76113: mbstring does not build with Oniguruma 6.8.1
| * Merge branch 'PHP-7.1' into PHP-7.2Christoph M. Becker2018-03-201-1/+1
| |\ | | | | | | | | | | | | * PHP-7.1: Fix #76113: mbstring does not build with Oniguruma 6.8.1
| | * Fix #76113: mbstring does not build with Oniguruma 6.8.1Christoph M. Becker2018-03-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | As of Oniguruma 6.8.1, the regex structure has been moved from the public `oniguruma.h` to the private `regint.h`. Thus, it is no longer possible to directly access the struct's members, and actually, there is no need to, since there are respective accessor functions available at least of 2.3.1.
| | * year++Xinchen Hui2018-01-021-1/+1
| | |
| | * Update copyright headers to 2017Sammy Kaye Powers2017-01-041-1/+1
| | |
| * | year++Xinchen Hui2018-01-021-1/+1
| | |
* | | Trailing whitespacesGabriel Caruso2018-01-031-1/+1
| | | | | | | | | | | | Signed-off-by: Gabriel Caruso <carusogabriel34@gmail.com>
* | | year++Xinchen Hui2018-01-021-1/+1
| | |
* | | Move constants into read-only data segmentDmitry Stogov2017-12-141-3/+3
| | |
* | | Use Zend MM heapDmitry Stogov2017-11-011-4/+4
|/ /
* | Remove more unnecessary checks on Zend's allocator functionsThomas Punt2017-03-161-3/+0
| |
* | Update copyright headers to 2017Sammy Kaye Powers2017-01-021-1/+1
|/
* Fixed bug #73646 (mb_ereg_search_init null pointer dereference)Xinchen Hui2016-12-091-6/+6
|
* Fixed bug #73532 (Null pointer dereference in mb_eregi)Xinchen Hui2016-11-161-2/+4
|
* Fix #72711: `mb_ereg` does not clear the `$regs` parameter on failureju1ius2016-08-051-2/+5
| | | | | When `mb_ereg` failed to match, it didn't update the `$regs` argument. Now it will always set it to the empty array.
* Merge branch 'PHP-7.0' into PHP-7.1Christoph M. Becker2016-07-301-1/+1
|\
| * Merge branch 'PHP-5.6' into PHP-7.0Christoph M. Becker2016-07-301-1/+1
| |\
| | * fixes bad address given to onig_error_code_to_strju1ius2016-07-301-1/+1
| | | | | | | | | | | | | | | | | | Closes bug #72710 (cherry picked from commit 0fb7eb6723bcc6fd98053911543e801edb5ab763)
* | | Merge branch 'PHP-7.0' into PHP-7.1Christoph M. Becker2016-07-281-1/+1
|\ \ \ | |/ / | | | | | | | | | # Resolved conflicts: # ext/mbstring/php_mbregex.c
| * | Merge branch 'PHP-5.6' into PHP-7.0Christoph M. Becker2016-07-281-1/+1
| |\ \ | | |/ | | | | | | | | | # Resolved conflicts: # ext/mbstring/php_mbregex.c
| | * Fix #72694: mb_ereg_search_setpos does not accept a string's last positionChristoph M. Becker2016-07-281-1/+1
| | | | | | | | | | | | | | | Setting the search position immediately behind the last character should be allowed, so we fix this off-by-one error.
* | | Merge branch 'PHP-7.0' into PHP-7.1Christoph M. Becker2016-07-281-1/+1
|\ \ \ | |/ /
| * | Merge branch 'PHP-5.6' into PHP-7.0Christoph M. Becker2016-07-281-1/+1
| |\ \ | | |/
| | * Fix #72693: mb_ereg_search increments search position when a match zero-widthChristoph M. Becker2016-07-281-1/+1
| | | | | | | | | | | | That's caused by an off-by-one error, which we fix.
* | | Merge branch 'PHP-7.0' into PHP-7.1Christoph M. Becker2016-07-281-3/+0
|\ \ \ | |/ /
| * | Merge branch 'PHP-5.6' into PHP-7.0Christoph M. Becker2016-07-281-3/+0
| |\ \ | | |/ | | | | | | | | | # Resolved conflicts: # ext/mbstring/php_mbregex.c
| | * Fix #72691: mb_ereg_search raises a warning if a match zero-widthChristoph M. Becker2016-07-281-3/+0
| | | | | | | | | | | | | | | That warning doesn't make sense (PCRE doesn't throw such a warning either), so we remove it.
* | | check the encoding of argument for mb_ereg, mb_ereg_replace, mb_ereg_search_initMasaki Kagaya2016-07-171-3/+29
| | |
* | | Implement RFC "Deprecate mb_ereg_replace eval option"Christoph M. Becker2016-07-111-0/+3
| | | | | | | | | | | | | | | <https://wiki.php.net/rfc/deprecate_mb_ereg_replace_eval_option> has been accepted, so we implement it.
* | | Merge branch 'throw-error-in-extensions'Aaron Piotrowski2016-07-051-2/+5
|\ \ \
| * | | Replace zend_ce_error with NULL and replace more E_ERROR with thrown ErrorAaron Piotrowski2016-06-131-2/+4
| | | |
| * | | Merge branch 'master' into throw-error-in-extensionsAaron Piotrowski2016-06-101-26/+30
| |\ \ \
| * | | | Update memory freeing and other issues, revert some changesAaron Piotrowski2015-07-051-1/+3
| | | | |
| * | | | Convert E_ERROR to thrown Error in extensionsAaron Piotrowski2015-07-051-2/+4
| | | | |
* | | | | Fixed compilation warningsDmitry Stogov2016-06-221-4/+5
| | | | |
* | | | | Merge branch 'PHP-7.0'Stanislav Malyshev2016-06-211-1/+0
|\ \ \ \ \ | | |_|/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * PHP-7.0: iFixed bug #72446 - Integer Overflow in gdImagePaletteToTrueColor() resulting in heap overflow update NEWS fix tests fix build Fix bug #72455: Heap Overflow due to integer overflows Fix bug #72434: ZipArchive class Use After Free Vulnerability in PHP's GC algorithm and unserialize Fixed ##72433: Use After Free Vulnerability in PHP's GC algorithm and unserialize Fix bug #72407: NULL Pointer Dereference at _gdScaleVert Fix bug #72402: _php_mb_regex_ereg_replace_exec - double free Fix bug #72298 pass2_no_dither out-of-bounds access Fixed #72339 Integer Overflow in _gd2GetHeader() resulting in heap overflow Fix bug #72262 - do not overflow int Fix bug #72400 and #72403 - prevent signed int overflows for string lengths Fix bug #72275: don't allow smart_str to overflow int Fix bug #72340: Double Free Courruption in wddx_deserialize Fix bug #72321 - use efree() for emalloc allocation 5.6.23RC1 fix NEWS set versions
| * | | | Merge branch 'PHP-7.0.8' into PHP-7.0Stanislav Malyshev2016-06-211-1/+0
| |\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * PHP-7.0.8: iFixed bug #72446 - Integer Overflow in gdImagePaletteToTrueColor() resulting in heap overflow update NEWS fix tests fix build Fix bug #72455: Heap Overflow due to integer overflows Fix bug #72434: ZipArchive class Use After Free Vulnerability in PHP's GC algorithm and unserialize Fixed ##72433: Use After Free Vulnerability in PHP's GC algorithm and unserialize Fix bug #72407: NULL Pointer Dereference at _gdScaleVert Fix bug #72402: _php_mb_regex_ereg_replace_exec - double free Fix bug #72298 pass2_no_dither out-of-bounds access Fixed #72339 Integer Overflow in _gd2GetHeader() resulting in heap overflow Fix bug #72262 - do not overflow int Fix bug #72400 and #72403 - prevent signed int overflows for string lengths Fix bug #72275: don't allow smart_str to overflow int Fix bug #72340: Double Free Courruption in wddx_deserialize Fix bug #72321 - use efree() for emalloc allocation 5.6.23RC1 fix NEWS set versions Conflicts: configure.in main/php_version.h
| | * \ \ \ Merge branch 'PHP-5.6.23' into PHP-7.0.8Stanislav Malyshev2016-06-211-1/+0
| | |\ \ \ \ | | | | |_|/ | | | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * PHP-5.6.23: (24 commits) iFixed bug #72446 - Integer Overflow in gdImagePaletteToTrueColor() resulting in heap overflow update NEWS fix tests fix build Fix bug #72455: Heap Overflow due to integer overflows Fix bug #72434: ZipArchive class Use After Free Vulnerability in PHP's GC algorithm and unserialize Fixed ##72433: Use After Free Vulnerability in PHP's GC algorithm and unserialize Fix bug #72407: NULL Pointer Dereference at _gdScaleVert Fix bug #72402: _php_mb_regex_ereg_replace_exec - double free Fix bug #72298 pass2_no_dither out-of-bounds access Fixed #72339 Integer Overflow in _gd2GetHeader() resulting in heap overflow Fix bug #72262 - do not overflow int Fix bug #72400 and #72403 - prevent signed int overflows for string lengths Fix bug #72275: don't allow smart_str to overflow int Fix bug #72340: Double Free Courruption in wddx_deserialize update NEWS Fix #66387: Stack overflow with imagefilltoborder Fix bug #72321 - use efree() for emalloc allocation 5.6.23RC1 Fix bug #72140 (segfault after calling ERR_free_strings()) ... Conflicts: configure.in ext/mbstring/php_mbregex.c ext/mcrypt/mcrypt.c ext/spl/spl_array.c ext/spl/spl_directory.c ext/standard/php_smart_str.h ext/standard/string.c ext/standard/url.c ext/wddx/wddx.c ext/zip/php_zip.c main/php_version.h
| | | * | | Merge branch 'PHP-5.5' into PHP-5.6.23Stanislav Malyshev2016-06-211-33/+32
| | | |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * PHP-5.5: Fixed bug #72446 - Integer Overflow in gdImagePaletteToTrueColor() resulting in heap overflow update NEWS fix tests fix build Fix bug #72455: Heap Overflow due to integer overflows Fix bug #72434: ZipArchive class Use After Free Vulnerability in PHP's GC algorithm and unserialize Fixed ##72433: Use After Free Vulnerability in PHP's GC algorithm and unserialize Fix bug #72407: NULL Pointer Dereference at _gdScaleVert Fix bug #72402: _php_mb_regex_ereg_replace_exec - double free Fix bug #72298 pass2_no_dither out-of-bounds access Fixed #72339 Integer Overflow in _gd2GetHeader() resulting in heap overflow Fix bug #72262 - do not overflow int Fix bug #72400 and #72403 - prevent signed int overflows for string lengths Fix bug #72275: don't allow smart_str to overflow int Fix bug #72340: Double Free Courruption in wddx_deserialize update NEWS Fix #66387: Stack overflow with imagefilltoborder Skip test which is 64bits only 5.5.37 now Conflicts: configure.in ext/mcrypt/mcrypt.c ext/spl/spl_directory.c main/php_version.h
| | | | * | | Fix bug #72402: _php_mb_regex_ereg_replace_exec - double freeStanislav Malyshev2016-06-181-33/+32
| | | | | | |
| | | | * | | Bump yearXinchen Hui2015-01-151-1/+1
| | | | | | |