Christoph M. Becker
e2100619ac
Expect appropriate parameter type in the first place
...
`mb_encode_numericentity()` and `mb_decode_numericentity()` accepted
arbitrary zvals as `$convmap`, but ignored anything else than arrays.
This appears to be an unresolved relict of their ZPP conversion for
PHP 5.3[1]. We now expect an array in the first place.
We also expect `count($convmap)` to be a multiple of four (else we
throw a `ValueError`), and do no longer special case empty `$convmap`.
[1] <http://git.php.net/?p=php-src.git;a=commit;h=1c77f594294aee9d60e7309279c616c01c39ba9d >
2019-10-07 16:48:08 +02:00
Nikita Popov
2fcd454480
Merge branch 'PHP-7.4'
2019-10-07 10:51:22 +02:00
Nikita Popov
5b067163be
Limit retry_limit test to oniguruma >= 6.9.3
...
This test is somewhat fragile in that it depends on how well a
particular regex is optimized. Apparently on 6.9.1 this regex
would hit the default retry_limit of 1000000 already. I'm limiting
this to 6.9.3 because that's the version that works for me.
2019-10-07 10:49:34 +02:00
Christoph M. Becker
8f7238ed5c
Explicitly declare empty parameter list
2019-10-06 19:04:51 +02:00
Christoph M. Becker
058fed6cd9
Just return on failing ZPP
2019-10-06 18:00:17 +02:00
Christoph M. Becker
013506779c
Add missing zend_parse_parameters_none()
2019-10-06 17:56:40 +02:00
Christoph M. Becker
0a47096c08
Add MBString arginfo stubs
2019-10-06 17:45:32 +02:00
Nikita Popov
21e631e473
Merge branch 'PHP-7.4'
2019-10-06 10:07:57 +02:00
Nikita Popov
6623e7ac51
Add support for mbstring.regex_retry_limit
...
This is very similar to the existing mbstring.regex_stack_limit,
but for backtracking. The default value matches pcre.backtrack_limit.
Only used on libonig >= 2.8.0.
2019-10-06 10:06:33 +02:00
Christoph M. Becker
b1468169dc
Merge branch 'PHP-7.4'
...
* PHP-7.4:
Skip tests for old versions instead of marking them XFAIL
2019-09-30 14:14:59 +02:00
Christoph M. Becker
3d89f92784
Skip tests for old versions instead of marking them XFAIL
...
According to commit 0eea9a6[1], these tests fail with old Oniguruma
versions; we are not sure which version of Oniguruma is required to let
them pass, but at least 6.9.3 is sufficient.
[1] <http://git.php.net/?p=php-src.git;a=commit;h=0eea9a642941ab5d4c612f8092f186977afbb73e >
2019-09-30 14:14:23 +02:00
Christoph M. Becker
d0d7508d1b
Merge branch 'PHP-7.4'
...
* PHP-7.4:
Fix #78609 : mb_check_encoding() no longer supports stringable objects
2019-09-30 13:07:19 +02:00
Christoph M. Becker
70f367d48a
Merge branch 'PHP-7.3' into PHP-7.4
...
* PHP-7.3:
Fix #78609 : mb_check_encoding() no longer supports stringable objects
2019-09-30 13:06:57 +02:00
Christoph M. Becker
2046b3ce4f
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fix #78609 : mb_check_encoding() no longer supports stringable objects
2019-09-30 13:04:54 +02:00
Christoph M. Becker
45db6fa567
Fix #78609 : mb_check_encoding() no longer supports stringable objects
...
We apply type juggling for other types than array.
2019-09-30 12:42:04 +02:00
Gabriel Caruso
5d6e923d46
Remove mention of PHP major version in Copyright headers
...
Closes GH-4732.
2019-09-25 14:51:43 +02:00
Stanislav Malyshev
a9dabe0e20
Merge branch 'PHP-7.4'
...
* PHP-7.4:
Fix #78559 : Heap buffer overflow in mb_eregi
2019-09-23 21:51:26 -07:00
Stanislav Malyshev
e7befd38d4
Merge branch 'PHP-7.3' into PHP-7.4
...
* PHP-7.3:
Fix #78559 : Heap buffer overflow in mb_eregi
2019-09-23 21:51:12 -07:00
Christoph M. Becker
8f949eba80
Fix #78559 : Heap buffer overflow in mb_eregi
...
We backport kkos/oniguruma@d3e402928b .
2019-09-23 21:49:55 -07:00
Christoph M. Becker
48892e6d24
Remove unused parameter
...
Cf. <https://bugs.php.net/78579 >.
2019-09-21 16:30:17 +02:00
Christoph M. Becker
8293667f60
Merge branch 'PHP-7.4'
...
* PHP-7.4:
Fix #78579 : mb_decode_numericentity: args number inconsistency
2019-09-21 16:18:20 +02:00
Christoph M. Becker
6dea11acd8
Merge branch 'PHP-7.3' into PHP-7.4
...
* PHP-7.3:
Fix #78579 : mb_decode_numericentity: args number inconsistency
2019-09-21 16:17:45 +02:00
Christoph M. Becker
698088ca7c
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fix #78579 : mb_decode_numericentity: args number inconsistency
2019-09-21 16:16:52 +02:00
Christoph M. Becker
398b308316
Fix #78579 : mb_decode_numericentity: args number inconsistency
...
mb_decode_numericentity() accepts a fourth optional parameter, which is
unused, however. Since this parameter doesn't do any harm, and to avoid
the small BC break, we're keeping this parameter for PHP 7, but adjust
the arginfo.
For PHP 8, we will remove this parameter.
2019-09-21 16:15:23 +02:00
Christoph M. Becker
6bd5567ce7
Merge branch 'PHP-7.4'
...
* PHP-7.4:
Add missing SKIPIF (mbstring)
2019-09-04 08:51:24 +02:00
Fabien Villepinte
db4f5e44e1
Add missing SKIPIF (mbstring)
2019-09-04 08:51:03 +02:00
Stanislav Malyshev
5748cec3ee
Upgrade oniguruma lib to 6.9.3
2019-08-27 23:40:46 -07:00
Stanislav Malyshev
d3f2cfe20a
Update Oniguruma to 6.9.1
2019-08-25 00:02:32 -07:00
Stanislav Malyshev
5704eca6f7
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fix CVE-2019-13224: don't allow different encodings for onig_new_deluxe()
set version for release
2019-08-24 23:16:09 -07:00
Stanislav Malyshev
087cb7bab2
Merge branch 'PHP-7.1' into PHP-7.2
...
* PHP-7.1:
Fix CVE-2019-13224: don't allow different encodings for onig_new_deluxe()
set version for release
2019-08-24 23:15:36 -07:00
Stanislav Malyshev
1258303e66
Fix CVE-2019-13224: don't allow different encodings for onig_new_deluxe()
...
Backport from 0f7f61ed1b
2019-08-24 23:11:45 -07:00
George Peter Banyard
1059e3dc39
Promote warnings to errors in str_repeat()
2019-08-23 20:01:19 +02:00
George Peter Banyard
ab76c613fe
Normalise strr(i)pos offset messages with str(i)pos ones.
2019-08-22 12:56:32 +02:00
Nikita Popov
8edf59ce29
Merge branch 'PHP-7.4'
2019-08-09 16:34:47 +02:00
Nikita Popov
7b152990b6
Don't short-circuit MBFL_OUTPUTFILTER_ILLEGAL_MODE_NONE
...
Make sure we always go through mbfl_filt_conv_illegal_output(), so
that the number of illegal characters gets counted.
2019-08-09 16:33:21 +02:00
Nikita Popov
36db71df47
Merge branch 'PHP-7.4'
2019-07-22 12:28:40 +02:00
Nikita Popov
39e756e7fe
Deprecate encoding as 3rd param to mb_strrpos()
2019-07-22 11:39:52 +02:00
Christoph M. Becker
257064de1a
Merge branch 'PHP-7.4'
...
* PHP-7.4:
Put oniguruma include path to proper CFLAGS
2019-07-19 20:05:08 +02:00
Christoph M. Becker
737c1b492c
Put oniguruma include path to proper CFLAGS
2019-07-19 20:04:47 +02:00
Christoph M. Becker
3060a4cf52
Merge branch 'PHP-7.4'
...
* PHP-7.4:
Move Oniguruma related config stuff to where it belongs
2019-07-19 19:31:58 +02:00
Christoph M. Becker
504cd03fc3
Move Oniguruma related config stuff to where it belongs
...
Oniguruma is exclusively used by ext/mbstring, and only if mbregex is
enabled. Therefore it is unnecessary and confusing to have Oniguruma
related config stuff scattered elsewhere.
While we're at it, we also remove the referral to the bundled libonig
which is removed as of PHP 7.4.0, and the duplicated call to
`PHP_INSTALL_HEADERS()`.
2019-07-19 19:30:41 +02:00
Peter Kokot
22583b20bc
Merge branch 'PHP-7.4'
...
* PHP-7.4:
Fix typo
Remove unused defines
2019-07-18 02:23:46 +02:00
Peter Kokot
359a78b16c
Remove unused defines
...
Used in php-src the past and today removed and not used anymore:
- HAVE_CURL_EASY_STRERROR
- HAVE_CURL_MULTI_STRERROR
- HAVE_NEW_MIME2TEXT
- HAVE_MBSTR_CN
- HAVE_MBSTR_JA
- HAVE_MBSTR_KR
- HAVE_MBSTR_RU
- HAVE_MBSTR_TW
Part of oniguruma which doesn't use these anymore
- NOT_RUBY
- HAVE_STDARG_PROTOTYPES
Unused:
- HAVE_MPIR
Closes GH-4427
2019-07-18 02:21:39 +02:00
Nikita Popov
8fc58a1a1d
Merge branch 'PHP-7.4'
2019-07-01 11:14:54 +02:00
Nikita Popov
7defd5f69c
Fix unused variable warnings when mbregex disabled
2019-07-01 11:14:35 +02:00
Nikita Popov
d2a1fe8462
Merge branch 'PHP-7.4'
2019-06-25 10:26:20 +02:00
Nikita Popov
46bad1d679
Fix region leak in mb_ereg_replace
2019-06-25 10:25:44 +02:00
Nikita Popov
3645292235
Merge branch 'PHP-7.4'
2019-06-19 15:09:39 +02:00
Nikita Popov
ae2bc6297e
Fix shift UB in mbfilter_utf32.c
2019-06-19 15:09:00 +02:00
Dmitry Stogov
e029cc4dd4
Merge branch 'PHP-7.4'
...
* PHP-7.4:
Cheaper checks for exceptions thrown from __toString()
2019-06-06 02:23:17 +03:00