Gina Peter Banyard
e7891838a1
ext/standard: Sync parameter names for fpow() to be identical to pow()
...
Closes GH-16751
2024-11-11 13:04:46 +00:00
FraOre
7bbf2eae8c
[skip ci] Fix array_any() and array_all() descriptions
...
Closes GH-16731.
2024-11-08 20:02:14 +01:00
Ilija Tovilo
230defc198
Merge branch 'PHP-8.3' into PHP-8.4
...
* PHP-8.3:
Fix array going away during sorting
2024-11-04 15:51:24 +01:00
Ilija Tovilo
f033cf75e4
Merge branch 'PHP-8.2' into PHP-8.3
...
* PHP-8.2:
Fix array going away during sorting
2024-11-04 15:51:03 +01:00
Ilija Tovilo
2bdce61390
Fix array going away during sorting
...
Fixes GH-16648
Closes GH-16654
2024-11-04 15:50:35 +01:00
Arnaud Le Blanc
4c212b305f
Merge branch 'PHP-8.3' into PHP-8.4
...
* PHP-8.3:
Fix tests: Prevent stack overflow during dtor
2024-10-24 15:58:12 +02:00
Arnaud Le Blanc
f3e87e2a6d
Fix tests: Prevent stack overflow during dtor
...
On s390x the stack is smaller and/or the object dtor code uses more stack,
which causes the destruction of deeply nested objects to crash in these
tests. Here I ensure that objects are released one by one at the end of the
tests to avoid recursive dtor.
Closes GH-16561
Fixes GH-16528
2024-10-24 15:56:25 +02:00
Ilija Tovilo
5f2f1a5702
Merge branch 'PHP-8.3' into PHP-8.4
...
* PHP-8.3:
Fix exception in assert() callback with bail enabled
2024-10-14 14:01:16 +02:00
Ilija Tovilo
f512ff4afa
Merge branch 'PHP-8.2' into PHP-8.3
...
* PHP-8.2:
Fix exception in assert() callback with bail enabled
2024-10-14 14:00:20 +02:00
Ilija Tovilo
b5c09b1a61
Fix exception in assert() callback with bail enabled
...
Fixes GH-16293
Closes GH-16304
2024-10-14 13:59:26 +02:00
Calvin Buckley
4643386703
Fix regression on platforms without ZEND_CHECK_STACK_LIMIT set (8.4) ( #16285 )
...
The check called an API only available with this def set.
Gate the check behind ifdef and change control flow to better fit it.
Co-authored-by: Arnaud Le Blanc <arnaud.lb@gmail.com >
2024-10-08 10:22:23 -03:00
Niels Dossche
612a6ad0af
Use standard error message for stack limit in serialize()
...
With GH-16204 merged, we can use the standard error message for the
recently-merged GH-16159.
Closes GH-16225.
2024-10-04 20:09:45 +02:00
Niels Dossche
577eb68212
Merge branch 'PHP-8.3' into PHP-8.4
...
* PHP-8.3:
Fix GH-15169: stack overflow when var serialization in ext/standard/var
2024-10-02 21:32:20 +02:00
Niels Dossche
bd724bdf42
Fix GH-15169: stack overflow when var serialization in ext/standard/var
...
Adding a stack check here as I consider serialization to be a more
sensitive place where erroring out with an exception seems appropriate.
Closes GH-16159.
2024-10-02 21:30:59 +02:00
Arnaud Le Blanc
3952a8f9f1
Merge branch 'PHP-8.3' into PHP-8.4
...
* PHP-8.3:
[ci skip] NEWS for GH-16061
Fix array_merge_recursive(): convert_to_array() may need separation (#16061 )
2024-10-02 12:44:00 +02:00
Arnaud Le Blanc
220c8828cc
Merge branch 'PHP-8.2' into PHP-8.3
...
* PHP-8.2:
[ci skip] NEWS for GH-16061
Fix array_merge_recursive(): convert_to_array() may need separation (#16061 )
2024-10-02 12:43:48 +02:00
Arnaud Le Blanc
545bef8ae6
Fix array_merge_recursive(): convert_to_array() may need separation ( #16061 )
2024-10-02 12:37:04 +02:00
David Carlier
4ad12bdd2d
Merge branch 'PHP-8.3' into PHP-8.4
2024-09-30 18:11:25 +01:00
David Carlier
d828308095
Merge branch 'PHP-8.2' into PHP-8.3
2024-09-30 18:11:14 +01:00
David Carlier
332b067c5e
Fix GH-15937: stream timeout option overflow.
...
close GH-15942
2024-09-30 18:10:33 +01:00
Christoph M. Becker
ebee8df27e
Merge branch 'PHP-8.3' into PHP-8.4
...
* PHP-8.3:
Fix potential parallel test conflicts
2024-09-29 02:13:06 +02:00
Christoph M. Becker
a17634c029
Merge branch 'PHP-8.2' into PHP-8.3
...
* PHP-8.2:
Fix potential parallel test conflicts
2024-09-29 02:11:48 +02:00
Christoph M. Becker
f5649556ea
Fix potential parallel test conflicts
...
Both tests call `create_files()` with the same `$name_prefix` what
might clash.
Co-authored-by: Gina Peter Banyard <girgias@php.net >
Closes GH-16103.
2024-09-29 02:05:14 +02:00
Ilija Tovilo
28d88c72bc
Merge branch 'PHP-8.3' into PHP-8.4
...
* PHP-8.3:
Reduce regex backtracking in phpinfo.phpt
2024-09-27 17:10:58 +02:00
Ilija Tovilo
0226e5d01d
Merge branch 'PHP-8.2' into PHP-8.3
...
* PHP-8.2:
Reduce regex backtracking in phpinfo.phpt
2024-09-27 17:10:47 +02:00
Ilija Tovilo
c4c45da4b9
Reduce regex backtracking in phpinfo.phpt
...
On NixOS, the output of phpinfo() can get very large, causing us to run into the
backtracking limit. Lazy matching for .*/.+ can help reduce backtracking.
2024-09-27 15:02:21 +02:00
Christoph M. Becker
f44250c418
Merge branch 'PHP-8.3'
...
* PHP-8.3:
Fix GH-15980: Signed integer overflow in main/streams/streams.c
2024-09-24 12:35:06 +02:00
Christoph M. Becker
acee803e6a
Merge branch 'PHP-8.2' into PHP-8.3
...
* PHP-8.2:
Fix GH-15980: Signed integer overflow in main/streams/streams.c
2024-09-24 12:33:17 +02:00
Christoph M. Becker
81916758ec
Fix GH-15980: Signed integer overflow in main/streams/streams.c
...
We need to avoid signed integer overflows which are undefined behavior.
We catch that, and set `offset` to `ZEND_LONG_MAX` (which is also the
largest value of `zend_off_t` on all platforms). Of course, that seek
may fail, but even if it succeeds, the stream is no longer readable,
but that matches the current behavior for offsets near `ZEND_LONG_MAX`.
Closes GH-15989.
2024-09-24 12:32:00 +02:00
Gina Peter Banyard
064ea9c505
Inlines the behaviour of php_mkdir_ex() into plain wrapper mkdir handler ( #15520 )
...
This effectively inlines the behaviour of php_mkdir_ex() which is a deprecated API from at least 17 years ago, and also fixes some of the return values.
This also removes a dependency on ext/standard
2024-09-23 00:40:02 +01:00
Christoph M. Becker
8a5ada4e10
Merge branch 'PHP-8.3'
...
* PHP-8.3:
Revert "Fix GH-15980: Signed integer overflow in main/streams/streams.c"
2024-09-23 01:33:57 +02:00
Christoph M. Becker
a9fcf498e3
Merge branch 'PHP-8.2' into PHP-8.3
...
* PHP-8.2:
Revert "Fix GH-15980: Signed integer overflow in main/streams/streams.c"
2024-09-23 01:32:45 +02:00
Christoph M. Becker
ee95ee7216
Revert "Fix GH-15980: Signed integer overflow in main/streams/streams.c"
...
This reverts commit 6a04c79e41 , since the
new test case apparently fails on 64bit Linux, so this needs closer
investigation.
2024-09-23 01:31:05 +02:00
Christoph M. Becker
10008fb6e8
Merge branch 'PHP-8.3'
...
* PHP-8.3:
Fix GH-15980: Signed integer overflow in main/streams/streams.c
2024-09-23 00:30:29 +02:00
Christoph M. Becker
c701508e6b
Merge branch 'PHP-8.2' into PHP-8.3
...
* PHP-8.2:
Fix GH-15980: Signed integer overflow in main/streams/streams.c
2024-09-23 00:29:15 +02:00
Christoph M. Becker
6a04c79e41
Fix GH-15980: Signed integer overflow in main/streams/streams.c
...
We need to avoid signed integer overflows which are undefined behavior.
We catch that, and set `offset` to `ZEND_LONG_MAX` (which is also the
largest value of `zend_off_t` on all platforms). Of course, after such
a seek a stream is no longer readable, but that matches the current
behavior for offsets near `ZEND_LONG_MAX`.
Closes GH-15989.
2024-09-23 00:28:09 +02:00
Niels Dossche
5bfd45cd44
Merge branch 'PHP-8.3'
...
* PHP-8.3:
Fix GH-15908 and GH-15026: leak / assertion failure in streams.c
2024-09-22 16:09:21 +02:00
Niels Dossche
94c2ae616b
Merge branch 'PHP-8.2' into PHP-8.3
...
* PHP-8.2:
Fix GH-15908 and GH-15026: leak / assertion failure in streams.c
2024-09-22 16:08:51 +02:00
Niels Dossche
018c0b3d14
Fix GH-15908 and GH-15026: leak / assertion failure in streams.c
...
This was first reported as a leak in GH-15026, but was mistakingly
believed to be a false positive. Then an assertion was added and it got
triggered in GH-15908. This fixes the leak. Upon merging into master the
assertion should be removed as well.
Closes GH-15924.
2024-09-22 16:07:12 +02:00
Niels Dossche
27b3131422
Fix GH-15982: Assertion failure with array_find when references are involved
...
Closes GH-15983.
2024-09-22 14:34:55 +02:00
Ilija Tovilo
1b9568d354
Implement backed enum coercion in http_build_query()
...
Fixes GH-15650
Closes GH-15704
2024-09-19 00:27:09 +02:00
Michael Voříšek
d313ad6098
Deprecate E_STRICT constant and remove error level
...
RFC: https://wiki.php.net/rfc/deprecations_php_8_4#remove_e_strict_error_level_and_deprecate_e_strict_constant
Closes GH-13053
2024-09-18 14:33:14 +02:00
Gina Peter Banyard
ae4ef32d68
ext/standard/browscap.c: Minor refactorings ( #15885 )
...
- Use more appropriate types
- Add const modifiers
- Reduce scope of some variable
- Prevent shadowing of variable
2024-09-17 16:48:21 +01:00
Gina Peter Bnayard
3f1a4441bd
ext/standard: Make char* of php_stristr() const
2024-09-14 14:00:46 +01:00
Gina Peter Banyard
f756b96e06
Make CSV deprecation less annoying to deal with ( #15569 )
2024-09-13 15:07:26 +01:00
Gina Peter Bnayard
ab99161444
ext/standard/versioning.c: Slightly refactor compare_special_version_forms()
2024-09-12 18:13:01 +01:00
Gina Peter Bnayard
8109d21065
ext/standard/url.c: Stop exposing php_replace_controlchars_ex()
...
This is not used from a quick search on SourceGraph and this allows us to refactor it
2024-09-12 18:13:01 +01:00
Gina Peter Bnayard
d45eb46c97
ext/standard/type.c: Remove unused include
2024-09-12 18:13:01 +01:00
Gina Peter Bnayard
85e6688791
ext/standard/string.c: Remove to(upper|lower) PHP API in favour of Zend APIs
2024-09-12 18:13:01 +01:00
Gina Peter Bnayard
1b87772f40
ext/standard/string.c: Refactor php_spn_common_handler()
...
Main objective is to remove the PHP_STR_STR(C)SPN symbols which are only used with this static function
2024-09-12 18:13:01 +01:00