commit: 6054776b57d63f9ec03263fa40c1d0a5aa99fb08 Author: Lothar Serra Mari <mail <AT> serra <DOT> me> AuthorDate: Fri Dec 19 10:40:56 2025 +0000 Commit: Michael Orlitzky <mjo <AT> gentoo <DOT> org> CommitDate: Sat Dec 20 12:54:48 2025 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6054776b
dev-lang/php: Drop obsolete patches * bug php/GH-20528 has been fixed upstream * support for libpcre2-10.47 has been added upstream Signed-off-by: Lothar Serra Mari <mail <AT> serra.me> Signed-off-by: Michael Orlitzky <mjo <AT> gentoo.org> .../php/files/php-8.4.14-libpcre2-testfix.patch | 61 ---------------- dev-lang/php/files/php-gh-20528-fix.patch | 81 ---------------------- 2 files changed, 142 deletions(-) diff --git a/dev-lang/php/files/php-8.4.14-libpcre2-testfix.patch b/dev-lang/php/files/php-8.4.14-libpcre2-testfix.patch deleted file mode 100644 index c33ceef2bf70..000000000000 --- a/dev-lang/php/files/php-8.4.14-libpcre2-testfix.patch +++ /dev/null @@ -1,61 +0,0 @@ -From 5f61eebf7a7a69e7ecfa87b5fe3ab49ccf4d3d56 Mon Sep 17 00:00:00 2001 -From: Michael Orlitzky <[email protected]> -Date: Wed, 5 Nov 2025 09:34:14 -0500 -Subject: [PATCH] ext/pcre/tests: support libpcre2-10.47 - -In the latest version of libpcre2, the offsets appearing in some -"compilation failed" warnings have increased by one, as a result of - - https://github.com/PCRE2Project/pcre2/pull/756 - -This is causing spurious test failures, so in this commit we replace -the hard-coded offsets by a regex that matches both values. - -Gentoo-bug: https://bugs.gentoo.org/965018 ---- - ext/pcre/tests/grep2.phpt | 2 +- - ext/pcre/tests/pcre_extra.phpt | 4 ++-- - ext/pcre/tests/split.phpt | 2 +- - 3 files changed, 4 insertions(+), 4 deletions(-) - -diff --git a/ext/pcre/tests/grep2.phpt b/ext/pcre/tests/grep2.phpt -index 9721dfbd9eec1..a953b13c49d54 100644 ---- a/ext/pcre/tests/grep2.phpt -+++ b/ext/pcre/tests/grep2.phpt -@@ -21,7 +21,7 @@ var_dump(preg_last_error() == PREG_RECURSION_LIMIT_ERROR); - - ?> - --EXPECTF-- --Warning: preg_grep(): Compilation failed: quantifier does not follow a repeatable item at offset 0 in %sgrep2.php on line %d -+Warning: preg_grep(): Compilation failed: quantifier does not follow a repeatable item at offset %r(0|1)%r in %sgrep2.php on line %d - bool(false) - array(3) { - [5]=> -diff --git a/ext/pcre/tests/pcre_extra.phpt b/ext/pcre/tests/pcre_extra.phpt -index 730c7299390cb..660e0a1488a1d 100644 ---- a/ext/pcre/tests/pcre_extra.phpt -+++ b/ext/pcre/tests/pcre_extra.phpt -@@ -8,8 +8,8 @@ var_dump(preg_match('/\y/X', '\y')); - - ?> - --EXPECTF-- --Warning: preg_match(): Compilation failed: unrecognized character follows \ at offset 1 in %spcre_extra.php on line 3 -+Warning: preg_match(): Compilation failed: unrecognized character follows \ at offset %r(1|2)%r in %spcre_extra.php on line 3 - bool(false) - --Warning: preg_match(): Compilation failed: unrecognized character follows \ at offset 1 in %spcre_extra.php on line 4 -+Warning: preg_match(): Compilation failed: unrecognized character follows \ at offset %r(1|2)%r in %spcre_extra.php on line 4 - bool(false) -diff --git a/ext/pcre/tests/split.phpt b/ext/pcre/tests/split.phpt -index df4b9af92f2f9..27f1c85b433ea 100644 ---- a/ext/pcre/tests/split.phpt -+++ b/ext/pcre/tests/split.phpt -@@ -16,7 +16,7 @@ var_dump(preg_split('/\d*/', 'ab2c3u', -1, PREG_SPLIT_NO_EMPTY)); - - ?> - --EXPECTF-- --Warning: preg_split(): Compilation failed: quantifier does not follow a repeatable item at offset 0 in %ssplit.php on line %d -+Warning: preg_split(): Compilation failed: quantifier does not follow a repeatable item at offset %r(0|1)%r in %ssplit.php on line %d - bool(false) - array(3) { - [0]=> diff --git a/dev-lang/php/files/php-gh-20528-fix.patch b/dev-lang/php/files/php-gh-20528-fix.patch deleted file mode 100644 index f8a790a48acd..000000000000 --- a/dev-lang/php/files/php-gh-20528-fix.patch +++ /dev/null @@ -1,81 +0,0 @@ -From 9d71c1e0b60cd152a47528dbe514efc443fce920 Mon Sep 17 00:00:00 2001 -From: Remi Collet <[email protected]> -Date: Thu, 20 Nov 2025 02:58:45 +0100 -Subject: [PATCH] Fix GH-20528: Regression breaks mysql connexion using an IPv6 - address enclosed in square brackets - ---- - ext/mysqli/tests/mysqli_connect_port.phpt | 31 +++++++++++++++++++++++ - ext/mysqlnd/mysqlnd_connection.c | 17 ++++++++++--- - 2 files changed, 45 insertions(+), 3 deletions(-) - create mode 100644 ext/mysqli/tests/mysqli_connect_port.phpt - -diff --git a/ext/mysqli/tests/mysqli_connect_port.phpt b/ext/mysqli/tests/mysqli_connect_port.phpt -new file mode 100644 -index 0000000000000..cb7fd1d8d1628 ---- /dev/null -+++ b/ext/mysqli/tests/mysqli_connect_port.phpt -@@ -0,0 +1,31 @@ -+--TEST-- -+mysqli_connect() with port in host -+--EXTENSIONS-- -+mysqli -+--SKIPIF-- -+<?php -+require_once 'skipifconnectfailure.inc'; -+?> -+--FILE-- -+<?php -+ require_once 'connect.inc'; -+ -+ // using port / host arguments -+ if (!$link = mysqli_connect($host, $user, $passwd, $db, $port, $socket)) { -+ printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n", -+ $host, $user, $db, $port, $socket); -+ } -+ -+ mysqli_close($link); -+ -+ // using port in host -+ if (!$link = mysqli_connect("$host:$port", $user, $passwd, $db, "1$port", $socket)) { -+ printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n", -+ "$host:$port", $user, $db, "1$port", $socket); -+ } -+ -+ mysqli_close($link); -+?> -+Done -+--EXPECTF-- -+Done -diff --git a/ext/mysqlnd/mysqlnd_connection.c b/ext/mysqlnd/mysqlnd_connection.c -index d8e7304e9665f..8268034e8b798 100644 ---- a/ext/mysqlnd/mysqlnd_connection.c -+++ b/ext/mysqlnd/mysqlnd_connection.c -@@ -553,13 +553,24 @@ MYSQLND_METHOD(mysqlnd_conn_data, get_scheme)(MYSQLND_CONN_DATA * conn, MYSQLND_ - port = 3306; - } - -- /* ipv6 addresses are in the format [address]:port */ - if (hostname.s[0] != '[' && mysqlnd_fast_is_ipv6_address(hostname.s)) { -+ /* IPv6 without square brackets so without port */ - transport.l = mnd_sprintf(&transport.s, 0, "tcp://[%s]:%u", hostname.s, port); - } else { -- /* Not ipv6, but could already contain a port number, in which case we should not add an extra port. -+ char *p; -+ -+ /* IPv6 addresses are in the format [address]:port */ -+ if (hostname.s[0] == '[') { /* IPv6 */ -+ p = strchr(hostname.s, ']'); -+ if (p && p[1] != ':') { -+ p = NULL; -+ } -+ } else { /* IPv4 or name */ -+ p = strchr(hostname.s, ':'); -+ } -+ /* Could already contain a port number, in which case we should not add an extra port. - * See GH-8978. In a port doubling scenario, the first port would be used so we do the same to keep BC. */ -- if (strchr(hostname.s, ':')) { -+ if (p) { - /* TODO: Ideally we should be able to get rid of this workaround in the future. */ - transport.l = mnd_sprintf(&transport.s, 0, "tcp://%s", hostname.s); - } else {
