Nikita Popov
5249993814
Fixed bug #78747
2019-10-25 12:47:18 +02:00
Joe Watkins
1c9b62fbd4
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fix bug #78697 : inaccurate error message
2019-10-21 09:23:26 +02:00
Fabien Villepinte
bea2ff88c9
Fix bug #78697 : inaccurate error message
2019-10-21 09:22:09 +02:00
Christoph M. Becker
4f50d58cab
Fix #78633 : Heap buffer overflow (read) in mb_eregi
...
We backport kkos/oniguruma@15c4228aa2 .
2019-10-20 22:47:38 -07:00
Christoph M. Becker
ce035dc4a0
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fix #78694 : Appending to a variant array causes segfault
2019-10-19 11:49:18 +02:00
Christoph M. Becker
45a7723267
Fix #78694 : Appending to a variant array causes segfault
...
`write_dimension` object handlers have to be able to handle `NULL`
`offset`s; for now we simply throw an exception instead of following
the `NULL` pointer.
2019-10-19 11:47:00 +02:00
Christoph M. Becker
c7c7ab53ac
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fix #70153 \DateInterval incorrectly unserialized
2019-10-18 15:32:08 +02:00
m.yakunin
d2cde0bfd3
Fix #70153 \DateInterval incorrectly unserialized
...
Added a separate macro for reading 'days' property, so that bool(false)
is correctly converted to the proper internal representation.
2019-10-18 15:31:14 +02:00
Derick Rethans
3725a446ba
Import timelib version 2018.03
2019-10-15 21:00:39 +01:00
Joe Watkins
22ac57b064
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fix checksum calculation for opcache
2019-10-14 16:49:48 +02:00
Mitch Hagstrand
e2a6bf482f
Fix checksum calculation for opcache
2019-10-14 16:46:42 +02:00
Christoph M. Becker
7439d48bea
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fix #78665 : Multicasting may leak memory
2019-10-12 14:44:55 +02:00
Christoph M. Becker
900bdcbd03
Fix #78665 : Multicasting may leak memory
2019-10-12 14:43:43 +02:00
Nikita Popov
74ac3dd6e2
Merge branch 'PHP-7.2' into PHP-7.3
2019-10-10 16:14:37 +02:00
Nikita Popov
46561dab6a
Fix leak in phar open
2019-10-10 16:14:21 +02:00
Nikita Popov
a0163417ef
Merge branch 'PHP-7.2' into PHP-7.3
2019-10-09 17:33:44 +02:00
Nikita Popov
daf1fc6e31
Avoid float to int cast UB in exif
2019-10-09 17:33:29 +02:00
Nikita Popov
cbf589b17c
Merge branch 'PHP-7.2' into PHP-7.3
2019-10-09 14:58:01 +02:00
Nikita Popov
d6ca174d5b
Remove redundant components < 0 check
...
components is an unsigned number, it cannot be smaller than zero.
2019-10-09 14:57:24 +02:00
Nikita Popov
736af5f660
Merge branch 'PHP-7.2' into PHP-7.3
2019-10-08 16:13:17 +02:00
Sergei Turchanov
a8f60ac9dd
Add pcre_get_compiled_regex_cache_ex() with local_aware flag
...
A new function `pcre_get_compiled_regex_cache_ex()` is introduced,
which allows to compile regexp pattern using the "C" locale instead
of a current locale.
This will be needed to replace setlocale() usage in fileinfo,
which is not thread-safe.
2019-10-08 16:11:55 +02:00
Christoph M. Becker
9fd555f99e
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Add missing SKIPIFs in exif tests
2019-10-08 14:12:12 +02:00
Fabien Villepinte
46894580b0
Add missing SKIPIFs in exif tests
2019-10-08 14:11:32 +02:00
Nikita Popov
2fdd142f99
Check for exception after applying stream filters
...
This makes the stream opening actually fail, and avoids assertion
failures when we tokenize with EG(exception) set.
Also avoid throwing an additional warning after an exception has
already been thrown.
2019-10-08 12:32:57 +02:00
Christoph M. Becker
d6fdc17f7f
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fix #78642 : Wrong libiconv version displayed
2019-10-08 12:10:06 +02:00
Christoph M. Becker
195c2008e8
Fix #78642 : Wrong libiconv version displayed
...
The high byte of `_libiconv_version` specifies the major version; the
low byte the minor version.
2019-10-08 12:09:11 +02:00
Christoph M. Becker
11654fdfa6
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fix #78641 : addGlob can modify given remove_path value
2019-10-08 09:48:59 +02:00
Christoph M. Becker
fd3118ffb0
Fix #78641 : addGlob can modify given remove_path value
...
`remove_path` points to the given string, so we must not modify it.
Instead we use a duplicate, if we need the modification.
We may want to switch to `zend_string`s in master.
2019-10-08 09:45:05 +02:00
Nikita Popov
8a03fd6a5e
Merge branch 'PHP-7.2' into PHP-7.3
2019-10-07 17:52:35 +02:00
Nikita Popov
19e6abebc7
Check for object_init_ex() failure in user filter factory
2019-10-07 17:52:29 +02:00
Nikita Popov
2624c9a505
Merge branch 'PHP-7.2' into PHP-7.3
2019-10-07 16:44:31 +02:00
Nikita Popov
7d19668f60
Set session.gc_probability=0 in bug78624.phpt
...
We only want to test manually triggered session GC.
Avoid spurious output due to automatic GC.
2019-10-07 16:43:19 +02:00
Nikita Popov
ab61d5caf9
Backport fix for uaf during pcre jit fallback
...
Backports parts of https://vcs.pcre.org/pcre2?view=revision&revision=1175
fixing https://bugs.exim.org/show_bug.cgi?id=2453 .
2019-10-07 13:23:56 +02:00
Christoph M. Becker
3322c78a88
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fix #78623 : Regression caused by "SP call yields additional empty result set"
2019-10-07 09:17:29 +02:00
Christoph M. Becker
114c03b9a6
Fix #78623 : Regression caused by "SP call yields additional empty result set"
...
This reverts commit 41a4379cb4
.
2019-10-07 09:15:51 +02:00
Nikita Popov
1d6e9da743
Improve diagnostic on PCRE JIT mmap failure
...
Print a more informative message that indicates that this is
likely a permission issue, and also indicate that pcre.jit=0
can be used to work around it.
Also automatically disable the JIT, so that this message is
only shown once.
See bug #78630 .
2019-10-04 16:03:38 +02:00
Christoph M. Becker
1ce8c805e2
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Split intl tests for ICU 65
2019-10-04 13:53:58 +02:00
Christoph M. Becker
545412a6cd
Split intl tests for ICU 65
2019-10-04 13:53:22 +02:00
Christoph M. Becker
cf183a5e2c
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fix #78620 : Out of memory error
2019-10-04 09:09:39 +02:00
Christoph M. Becker
abaf9a76dc
Fix #78620 : Out of memory error
...
The integer addition in `ZEND_MM_ALIGNED_SIZE_EX` can overflow, what we
have to catch early.
2019-10-04 09:08:01 +02:00
Joe Watkins
f45eb353d1
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
fix #78624 : session_gc return value for user defined session handlers
2019-10-04 06:12:29 +02:00
Brent Shaffer
a6d219630c
fix #78624 : session_gc return value for user defined session handlers
2019-10-04 06:12:02 +02:00
Joe Watkins
f4d078b1c7
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fix bug #76809 (SSL settings aren't respected when persistent connection is reused)
2019-10-03 06:57:05 +02:00
Fábio Souto
9a2b42a5c1
Fix bug #76809 (SSL settings aren't respected when persistent connection is reused)
2019-10-03 06:56:21 +02:00
Joe Watkins
5b1bb23edf
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fix #76859 stream_get_line skips data if used with data-generating filter
2019-10-03 06:51:10 +02:00
Konstantin Kopachev
05560b67bc
Fix #76859 stream_get_line skips data if used with data-generating filter
...
stream_get-line repeatedly calls php_stream_fill_read_buffer until
enough data is accumulated in buffer. However, when stream contains
filters attached to it, then each call to fill buffer essentially
resets buffer read/write pointers and new data is written over old.
This causes stream_get_line to skip parts of data from stream
This patch fixes such behavior, so fill buffer call will append.
2019-10-03 06:50:43 +02:00
Derick Rethans
0505fbf2e5
Updated to version 2019.3 (2019c)
2019-10-02 23:39:09 +01:00
Dmitry Stogov
f7596d1b5b
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fixed test that "fails" from time to time
2019-10-02 00:57:16 +03:00
Dmitry Stogov
3124129ca8
Fixed test that "fails" from time to time
2019-10-02 00:54:59 +03:00
Dmitry Stogov
848bc776ea
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fixed test that "fails" from time to time
2019-10-02 00:49:27 +03:00
Dmitry Stogov
2fcb5eadbb
Fixed test that "fails" from time to time
2019-10-02 00:48:42 +03:00
Christoph M. Becker
2fc5d00afa
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Add missing skip keyword in tests
2019-10-01 11:15:12 +02:00
Fabien Villepinte
209e37db7d
Add missing skip keyword in tests
2019-10-01 11:13:36 +02:00
Nikita Popov
0805e132b0
Merge branch 'PHP-7.2' into PHP-7.3
2019-09-30 15:06:32 +02:00
Nikita Popov
6fcde56b03
Fixed bug #78612
2019-09-30 15:06:07 +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
Christoph M. Becker
466f91bb3b
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fix build for libzip < 0.11.2
2019-09-29 13:34:16 +02:00
Christoph M. Becker
f6bfbe9553
Fix build for libzip < 0.11.2
...
We must not define method entries, if the actual method definitions or
the arginfo structures are not defined.
2019-09-29 13:33:18 +02:00
Christoph M. Becker
66c48e8694
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fix SKIPIF in ext/mysqli
2019-09-27 16:04:00 +02:00
Fabien Villepinte
37d27e666a
Fix SKIPIF in ext/mysqli
2019-09-27 16:03:20 +02:00
Christoph M. Becker
878704ff6f
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fix skipif.inc
2019-09-27 12:51:21 +02:00
Christoph M. Becker
115f6effec
Fix skipif.inc
2019-09-27 12:50:04 +02:00
Nikita Popov
915fe2fdc6
Merge branch 'PHP-7.2' into PHP-7.3
2019-09-25 10:34:25 +02:00
Jinesh Patel
d2331cc3f2
Fix hash key length in umsg_parse_format()
...
Fix array length passed to zend_hash_str_find_ptr() casting from
UChar array to char array requires mul by sizeof(UChar).
2019-09-25 10:30:33 +02: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
Nikita Popov
954d073833
Merge branch 'PHP-7.2' into PHP-7.3
2019-09-23 17:18:33 +02:00
Nikita Popov
3ddb63dce1
Fix skipif condition
2019-09-23 17:17:52 +02:00
Nikita Popov
d0f4966b05
Merge branch 'PHP-7.2' into PHP-7.3
2019-09-23 16:42:33 +02:00
Nikita Popov
bc4c4c658c
Skip test on 32-bit
2019-09-23 16:42:24 +02:00
Nikita Popov
087051c9a5
Skip test on 32-bit
2019-09-23 14:52:32 +02:00
Nikita Popov
1a184f030a
Commit regenerated var_unserializer.c
2019-09-23 13:47:05 +02:00
Nikita Popov
f53af9ac23
Merge branch 'PHP-7.2' into PHP-7.3
2019-09-23 13:18:39 +02:00
Nikita Popov
8509970e6a
Fix signed integer overflow in SplObjectStorage unserialization
...
If count is ZEND_LONG_MIN the count-- loop underflows. This is
ultimately harmless, but results in a ubsan warning.
Fix this by adding a sanity check that the count isn't negative,
because that doesn't make sense...
2019-09-23 13:18:27 +02:00
Nikita Popov
e65adc9c19
Fix ubsan violation in parse_iv2
...
This fixes two issues:
* Negative the value in an unsigned type to avoid signed overflow.
* Treat -0 as 0 rather than an invalid number that gets converted
to ZEND_LONG_MIN.
2019-09-23 13:08:44 +02:00
Christoph M. Becker
9c89f43d55
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fix test to be skipped if dom is not available
2019-09-22 18:42:40 +02:00
Christoph M. Becker
697945aa89
Fix test to be skipped if dom is not available
2019-09-22 18:42:02 +02:00
Nikita Popov
9cd365e571
Merge branch 'PHP-7.2' into PHP-7.3
2019-09-22 12:10:42 +02:00
Nikita Popov
f989a4cd44
Fix leak of temporary buffer during exif tag reading
2019-09-22 12:10:17 +02:00
Nikita Popov
623d897998
Merge branch 'PHP-7.2' into PHP-7.3
2019-09-22 10:26:57 +02:00
Nikita Popov
0701835c01
Fix multiple leaks in exif_read_data()
...
This fixes two leaks related to duplicate tags, as well as a leak
of zero-length FMT_(S)BYTE with non-null value. This can show up
for MAKERNOTE values where the original length is non-zero, but
the first character is a null byte.
2019-09-21 20:40:03 +02:00
Christoph M. Becker
33e556fab4
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fix length of key passed to zend_hash_str_find_ptr
2019-09-21 18:12:27 +02:00
Jinesh Patel
0d6c2448a7
Fix length of key passed to zend_hash_str_find_ptr
2019-09-21 18:11:21 +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
Nikita Popov
e76dea4283
Merge branch 'PHP-7.2' into PHP-7.3
2019-09-19 21:14:40 +02:00
Nikita Popov
0fa13028cb
Fix out-of-bounds read in exif tag reading
...
This issue was recently introduced in c739023a50
,
when the restriction that components>0 has been relaxed. We now need
to make sure that any tags that expect at least one component check
that this is the case.
2019-09-19 21:11:57 +02:00
Nikita Popov
85e7668129
Merge branch 'PHP-7.2' into PHP-7.3
2019-09-19 17:21:45 +02:00
Nikita Popov
003c13d7bc
Fix iterable return type optimization
2019-09-19 17:21:00 +02:00
Nikita Popov
6bf5c8508a
Merge branch 'PHP-7.2' into PHP-7.3
2019-09-19 14:20:04 +02:00
Nikita Popov
3e139a4653
Fix exif leak on duplicate copyright tags
2019-09-19 14:19:31 +02:00
Nikita Popov
f53b8268d6
Merge branch 'PHP-7.2' into PHP-7.3
2019-09-19 11:36:09 +02:00
CJDennis
e3255a4f49
Fix typo
...
`sizeof("data")-1` and `sizeof("date")-1` are both 4, so no change in behaviour
2019-09-19 11:36:00 +02:00
Nikita Popov
85b001974a
Remove unstable test output
...
This may be printed in a different order, and we don't care about
it anyway.
2019-09-18 16:36:29 +02:00
Nikita Popov
e11ed02870
Fixed bug #78272
...
Use MAP_JIT only when running under hardened runtime, because MAP_JIT
is incompatible with fork().
The check is based on
f879e35e3e
.
2019-09-18 10:41:27 +02:00
Nikita Popov
03efeda538
Backport MAP_JIT fixes from PCRE2 10.33
...
This is intended to fix the primary issue from bug #77260 .
Prior to macOS 10.14 multiple MAP_JIT segments were not permitted,
leading to mmap failures and corresponding "no more memory" errors
on macOS 10.13.
2019-09-18 09:28:54 +02:00
Nikita Popov
409e9ea51d
Merge branch 'PHP-7.2' into PHP-7.3
2019-09-17 17:34:08 +02:00
Nikita Popov
175f4f24ae
Increase timeout in test
2019-09-17 17:33:46 +02:00
Nikita Popov
c5d4c45e7d
Merge branch 'PHP-7.2' into PHP-7.3
2019-09-17 15:42:58 +02:00
fancyweb
e691a98c1f
Fix #76342 : file_get_contents waits twice specified timeout
2019-09-17 15:42:29 +02:00