1
0
mirror of https://github.com/php/php-src.git synced 2026-03-24 00:02:20 +01:00
Commit Graph

143154 Commits

Author SHA1 Message Date
Máté Kocsis
cd9eec79a8 Add Tim as a maintainer of ext/uri
[skip-ci]
2025-09-30 22:19:15 +02:00
Niels Dossche
f2aaea053c Use faster string construction in ext/dom in some places (#20005)
Many tag names are single characters, so we can use the fast string
construction. In cases where a NULL name is used we can also use the
empty string.
This avoids some allocations and some work.
2025-09-30 18:10:24 +02:00
Niels Dossche
f73bedbd1d Merge branch 'PHP-8.5'
* PHP-8.5:
  Fix GH-20009: XMLReader leak on RelaxNG schema failure
2025-09-30 18:07:24 +02:00
Niels Dossche
0f47d0de5e Merge branch 'PHP-8.4' into PHP-8.5
* PHP-8.4:
  Fix GH-20009: XMLReader leak on RelaxNG schema failure
2025-09-30 18:07:16 +02:00
Niels Dossche
58b45b5055 Merge branch 'PHP-8.3' into PHP-8.4
* PHP-8.3:
  Fix GH-20009: XMLReader leak on RelaxNG schema failure
2025-09-30 18:07:08 +02:00
Niels Dossche
c617afd6d6 Fix GH-20009: XMLReader leak on RelaxNG schema failure
Closes GH-20014.
2025-09-30 18:06:35 +02:00
Gina Peter Banyard
c7da728574 ext/filter: Check callback validity once (#19921)
The call_user_function() API redoes the zend_is_callable() check, which has been just done.

We can check validity and retrieve the FCC to call it directly rather than having a useless double check
2025-09-30 15:17:56 +01:00
Niels Dossche
44714a3254 Merge branch 'PHP-8.5'
* PHP-8.5:
  Fix NEWS formatting
2025-09-30 15:22:53 +02:00
Niels Dossche
d9e7790848 Merge branch 'PHP-8.4' into PHP-8.5
* PHP-8.4:
  Fix NEWS formatting
2025-09-30 15:22:47 +02:00
Niels Dossche
879c772772 Merge branch 'PHP-8.3' into PHP-8.4
* PHP-8.3:
  Fix NEWS formatting
2025-09-30 15:22:30 +02:00
Niels Dossche
d9ee711baf Fix NEWS formatting 2025-09-30 15:21:47 +02:00
Niels Dossche
f60dd15f95 Merge branch 'PHP-8.5'
* PHP-8.5:
  Fix bug #67563: mysqli compiled with mysqlnd does not take ipv6 adress as parameter
2025-09-30 15:21:19 +02:00
Niels Dossche
5fd378236f Merge branch 'PHP-8.4' into PHP-8.5
* PHP-8.4:
  Fix bug #67563: mysqli compiled with mysqlnd does not take ipv6 adress as parameter
2025-09-30 15:21:07 +02:00
Niels Dossche
4496322e42 Merge branch 'PHP-8.3' into PHP-8.4
* PHP-8.3:
  Fix bug #67563: mysqli compiled with mysqlnd does not take ipv6 adress as parameter
2025-09-30 15:20:50 +02:00
Niels Dossche
6db12e7cd8 Fix bug #67563: mysqli compiled with mysqlnd does not take ipv6 adress as parameter
In the past, when libmysqlclient could be used, it accepted ipv6 addresses
as hostname without enclosing it first in brackets. However, in mysqlnd
this never worked. In the past this caused a discrepancy between the two
implementations.
Nowadays, mysqli only works with mysqlnd so we don't even have to cater
to libmysqlclient. However, a plain ipv6 address should still work as a
hostname. Also for people migrating to newer PHP versions it's nice if
this keeps working.

The solution is to check if we're dealing with an ipv6 address not yet
enclosed in brackets. In that case we add the brackets automatically.

Closes GH-19750.
2025-09-30 15:20:14 +02:00
Niels Dossche
09f84ed1ac Merge branch 'PHP-8.5'
* PHP-8.5:
  Fix GH-20006: Power of 0 of BcMath number causes UB
2025-09-30 14:47:48 +02:00
Niels Dossche
a380dcae4d Fix GH-20006: Power of 0 of BcMath number causes UB
Closes GH-20007.
2025-09-30 14:47:35 +02:00
Niels Dossche
ba8472f579 Merge branch 'PHP-8.5'
* PHP-8.5:
  Fix GH-19998: ext/standard/tests/file/bug46347.phpt sometimes fails: racy in parallel
2025-09-30 10:53:32 +02:00
Niels Dossche
4ab1324a34 Merge branch 'PHP-8.4' into PHP-8.5
* PHP-8.4:
  Fix GH-19998: ext/standard/tests/file/bug46347.phpt sometimes fails: racy in parallel
2025-09-30 10:53:25 +02:00
Niels Dossche
7e47226fd6 Merge branch 'PHP-8.3' into PHP-8.4
* PHP-8.3:
  Fix GH-19998: ext/standard/tests/file/bug46347.phpt sometimes fails: racy in parallel
2025-09-30 10:53:17 +02:00
Niels Dossche
21c2c07a24 Fix GH-19998: ext/standard/tests/file/bug46347.phpt sometimes fails: racy in parallel
The same test file name is already used in parse_ini_file.phpt.

Closes GH-20000.
2025-09-30 10:52:59 +02:00
Ilija Tovilo
96aa0e08a1 Merge branch 'PHP-8.5'
* PHP-8.5:
  [skip ci] Fix NEWS formatting
2025-09-30 01:19:17 +02:00
Ilija Tovilo
836a556f73 [skip ci] Fix NEWS formatting 2025-09-30 01:18:56 +02:00
Ilija Tovilo
cc80a2baea Merge branch 'PHP-8.5'
* PHP-8.5:
  Fix fatal error during sccp shift eval
2025-09-30 01:17:09 +02:00
Ilija Tovilo
16a8591f28 Fix fatal error during sccp shift eval
Avoid returning early in this function, as other checks might still be needed to
verify whether the given function can procude an error.

Fixes oss-fuzz #447521098
Closes GH-19972
2025-09-30 01:16:40 +02:00
David Carlier
d21b207cd9 Merge branch 'PHP-8.5' 2025-09-29 23:21:18 +01:00
David Carlier
033dd8a8b7 Merge branch 'PHP-8.4' into PHP-8.5 2025-09-29 23:21:08 +01:00
David Carlier
1015de30f0 Merge branch 'PHP-8.3' into PHP-8.4 2025-09-29 23:20:38 +01:00
David Carlier
e029f8f45b Fix GH-19955: imagefttext() memory leak
close GH-19968
2025-09-29 23:20:27 +01:00
David Carlier
b34ca99c94 Merge branch 'PHP-8.5' 2025-09-29 22:49:12 +01:00
David Carlier
ed9c1b87ee Merge branch 'PHP-8.4' into PHP-8.5 2025-09-29 22:48:55 +01:00
David Carlier
03de7b0b28 Merge branch 'PHP-8.3' into PHP-8.4 2025-09-29 22:48:38 +01:00
David Carlier
93bac8cb1a Fix GH-19922: gzopen() double free
close GH-19924
2025-09-29 22:47:29 +01:00
David Carlier
590785ed21 Merge branch 'PHP-8.5' 2025-09-29 22:12:01 +01:00
David Carlier
2c4f4e0ee6 Merge branch 'PHP-8.4' into PHP-8.5 2025-09-29 22:11:49 +01:00
David Carlier
4e00b14029 Merge branch 'PHP-8.3' into PHP-8.4 2025-09-29 22:10:46 +01:00
David Carlier
3ee56f68ed Fix GH-19932: Zip::setEncryptionName()/setEncryptionIndex() memory leak.
On successive usage, the password is copied as much but the older
address is never freed. Thus, we are hinting a password reset to address
it.

close GH-19936
2025-09-29 22:10:17 +01:00
Tim Düsterhus
1f724104b5 Merge branch 'PHP-8.5'
* PHP-8.5:
  NEWS: Fix section order
  lexbor: Cherry pick "Core: Reset length in lexbor_str_destroy()"
2025-09-29 22:45:25 +02:00
Tim Düsterhus
c997212dbf NEWS: Fix section order 2025-09-29 22:44:39 +02:00
Tim Düsterhus
11ce662101 lexbor: Cherry pick "Core: Reset length in lexbor_str_destroy()"
see lexbor/lexbor@1bc9944a19

Fixes php/php-src#19979
2025-09-29 22:43:47 +02:00
Calvin Buckley
294a0801a5 ODBC fetch refactoring (#19848)
* Merge odbc_fetch_into into odbc_fetch_hash

Now that we can assume fetch_hash exists, there's a lot of redundancy in
these functions. Merge their implementations, and smooth over the
differences in how they handle returning their result set as an array.

* Convert php_odbc_fetch_hash to ZPP

* Use SQLFetchScroll instead of SQLExtendedFetch

Fixes GH-19522

* Convert result type constants to an enum

* Implement odbc_fetch_row in terms of php_odbc_fetch_hash

These are also doing extremely similar jobs, but with slightly different
behaviours for the return value (in this case, none, as it's tended to
be used with odbc_result). Unify this too.

The $row value deprecation for 0/-1 is only handled for odbc_fetch_row;
it's too late to do so for PHP 8.5. Should probably unify it for PHP 8.6.

* Rename php_odbc_fetch_hash to remove _hash

Since this is a much more shared fetch function now.
2025-09-29 12:45:45 -03:00
Gina Peter Banyard
c515c04b0a Zend: Convert _zend_op_array literal fields to uint32_t 2025-09-29 15:53:58 +01:00
Gina Peter Banyard
0a47dd9bb4 Zend: Convert _zend_op_array.last_try_catch field to uint32_t 2025-09-29 15:53:58 +01:00
Gina Peter Banyard
a94dc48567 Zend: Convert _zend_op_array.last_live_range field to uint32_t 2025-09-29 15:53:58 +01:00
Gina Peter Banyard
18ce83b2e3 Zend: Convert _zend_op_array.cache_size field to uint32_t 2025-09-29 15:53:58 +01:00
Gina Peter Banyard
299bd63177 Zend: Change return type of lookup_cv from int to uint32_t 2025-09-29 15:53:58 +01:00
Gina Peter Banyard
6b470cf5d8 Zend: Convert _zend_oparray_context.var_size field to uint32_t 2025-09-29 15:53:58 +01:00
Niels Dossche
8ea4d7b5fa Merge branch 'PHP-8.5'
* PHP-8.5:
  Fix uninitialized soap lang_en string on ZTS
2025-09-29 16:11:47 +02:00
Niels Dossche
8987c0b661 Fix uninitialized soap lang_en string on ZTS
Replaces GH-19772.
Closes GH-19772.
Fixes GH-19773.
Closes GH-19819.
2025-09-29 16:11:29 +02:00
Niels Dossche
4db8993ee2 Merge branch 'PHP-8.5'
* PHP-8.5:
  Fix NEWS order
  Fix GH-19988: zend_string_init with NULL pointer in simplexml (UB)
2025-09-29 16:09:07 +02:00