!192 [sync] PR-190: Update to version 8.3.10
From: @openeuler-sync-bot Reviewed-by: @dillon_chen Signed-off-by: @dillon_chen
This commit is contained in:
commit
51427475d1
Binary file not shown.
Binary file not shown.
@ -1,101 +0,0 @@
|
||||
From 86b93bc479477e6c0de6207bfe59c1e276dfdafb Mon Sep 17 00:00:00 2001
|
||||
From: Dmitry Stogov <dmitry@zend.com>
|
||||
Date: Wed, 5 Jun 2024 23:53:31 +0300
|
||||
Subject: [PATCH] Fix GH-14480: Method visibility issue introduced in version
|
||||
8.3.8 (#14484)
|
||||
|
||||
---
|
||||
Zend/tests/gh14480.phpt | 60 +++++++++++++++++++++++++++++++++++++++++
|
||||
Zend/zend_inheritance.c | 8 +++---
|
||||
2 files changed, 65 insertions(+), 3 deletions(-)
|
||||
create mode 100644 Zend/tests/gh14480.phpt
|
||||
|
||||
diff --git a/Zend/tests/gh14480.phpt b/Zend/tests/gh14480.phpt
|
||||
new file mode 100644
|
||||
index 0000000000000..bab74785b6b23
|
||||
--- /dev/null
|
||||
+++ b/Zend/tests/gh14480.phpt
|
||||
@@ -0,0 +1,60 @@
|
||||
+--TEST--
|
||||
+GH-14480: Method visibility issue
|
||||
+--FILE--
|
||||
+<?php
|
||||
+trait PropertyHelperTrait
|
||||
+{
|
||||
+ protected function splitPropertyParts(): void
|
||||
+ {
|
||||
+ echo "OK\n";
|
||||
+ }
|
||||
+}
|
||||
+
|
||||
+trait OrmPropertyHelperTrait
|
||||
+{
|
||||
+ abstract protected function splitPropertyParts(): void;
|
||||
+
|
||||
+ protected function addJoinsForNestedProperty(): void
|
||||
+ {
|
||||
+ $this->splitPropertyParts();
|
||||
+ }
|
||||
+}
|
||||
+
|
||||
+trait SearchFilterTrait
|
||||
+{
|
||||
+ use PropertyHelperTrait;
|
||||
+}
|
||||
+
|
||||
+abstract class AbstractFilter
|
||||
+{
|
||||
+ use OrmPropertyHelperTrait, PropertyHelperTrait;
|
||||
+
|
||||
+ public function apply(): void
|
||||
+ {
|
||||
+ $this->filterProperty();
|
||||
+ }
|
||||
+
|
||||
+ abstract protected function filterProperty(): void;
|
||||
+}
|
||||
+
|
||||
+class SearchFilter extends AbstractFilter
|
||||
+{
|
||||
+ use SearchFilterTrait;
|
||||
+ protected function filterProperty(): void
|
||||
+ {
|
||||
+ $this->addJoinsForNestedProperty();
|
||||
+ }
|
||||
+}
|
||||
+
|
||||
+class FilterExtension
|
||||
+{
|
||||
+ public function applyToCollection(): void
|
||||
+ {
|
||||
+ (new SearchFilter())->apply();
|
||||
+ }
|
||||
+}
|
||||
+
|
||||
+(new FilterExtension)->applyToCollection();
|
||||
+?>
|
||||
+--EXPECT--
|
||||
+OK
|
||||
diff --git a/Zend/zend_inheritance.c b/Zend/zend_inheritance.c
|
||||
index 402354baa8..228c5b6e54 100644
|
||||
--- a/Zend/zend_inheritance.c
|
||||
+++ b/Zend/zend_inheritance.c
|
||||
@@ -2018,12 +2018,14 @@ static void zend_add_trait_method(zend_class_entry *ce, zend_string *name, zend_
|
||||
if (check_inheritance) {
|
||||
/* Inherited members are overridden by members inserted by traits.
|
||||
* Check whether the trait method fulfills the inheritance requirements. */
|
||||
+ uint32_t flags = ZEND_INHERITANCE_CHECK_PROTO | ZEND_INHERITANCE_CHECK_VISIBILITY;
|
||||
+ if (!(existing_fn->common.scope->ce_flags & ZEND_ACC_TRAIT)) {
|
||||
+ flags |= ZEND_INHERITANCE_SET_CHILD_CHANGED |ZEND_INHERITANCE_SET_CHILD_PROTO |
|
||||
+ ZEND_INHERITANCE_RESET_CHILD_OVERRIDE;
|
||||
+ }
|
||||
do_inheritance_check_on_method(
|
||||
fn, fixup_trait_scope(fn, ce), existing_fn, fixup_trait_scope(existing_fn, ce),
|
||||
- ce, NULL,
|
||||
- ZEND_INHERITANCE_CHECK_PROTO | ZEND_INHERITANCE_CHECK_VISIBILITY |
|
||||
- ZEND_INHERITANCE_SET_CHILD_CHANGED| ZEND_INHERITANCE_SET_CHILD_PROTO |
|
||||
- ZEND_INHERITANCE_RESET_CHILD_OVERRIDE);
|
||||
+ ce, NULL, flags);
|
||||
}
|
||||
}
|
||||
/* }}} */
|
||||
29
php.spec
29
php.spec
@ -23,12 +23,12 @@
|
||||
%global with_modphp 1
|
||||
%global with_lmdb 1
|
||||
%global with_sodium 1
|
||||
%global upver 8.3.8
|
||||
%global upver 8.3.10
|
||||
|
||||
|
||||
Name: php
|
||||
Version: %{upver}
|
||||
Release: 2
|
||||
Release: 1
|
||||
Summary: PHP scripting language for creating dynamic web sites
|
||||
License: PHP-3.01 AND Zend-2.0 AND BSD-2-Clause AND MIT AND Apache-1.0 AND NCSA AND BSL-1.0
|
||||
URL: http://www.php.net/
|
||||
@ -62,10 +62,8 @@ Patch6: php-7.4.0-phpize.patch
|
||||
Patch7: php-7.4.0-ldap_r.patch
|
||||
Patch8: php-8.1.0-phpinfo.patch
|
||||
Patch9: php-8.3.0-openssl-ec-param.patch
|
||||
Patch10: php-gh14480.patch
|
||||
|
||||
|
||||
BuildRequires: gnupg2
|
||||
BuildRequires: bzip2-devel
|
||||
BuildRequires: pkgconfig(libcurl) >= 7.29.0
|
||||
BuildRequires: httpd-devel >= 2.0.46-1
|
||||
@ -589,22 +587,7 @@ Summary: help
|
||||
help
|
||||
|
||||
%prep
|
||||
%{?gpgverify:%{gpgverify} --keyring='%{SOURCE15}' --data='%{SOURCE0}'}
|
||||
|
||||
%setup -q -n php-%{upver}
|
||||
|
||||
%patch -P0 -p1 -b .mpmcheck
|
||||
%patch -P1 -p1 -b .includedir
|
||||
%patch -P2 -p1 -b .embed
|
||||
%patch -P3 -p1 -b .libdb
|
||||
|
||||
%patch -P4 -p1 -b .syslib
|
||||
%patch -P5 -p1 -b .systzdata
|
||||
%patch -P6 -p1 -b .headers
|
||||
%patch -P7 -p1 -b .ldap_r
|
||||
%patch -P8 -p1 -b .phpinfo
|
||||
%patch -P9 -p1 -b .datetests
|
||||
%patch -P10 -p1 -b .gh14480
|
||||
%autosetup -n php-%{upver} -p1
|
||||
|
||||
cp Zend/LICENSE ZEND_LICENSE
|
||||
cp TSRM/LICENSE TSRM_LICENSE
|
||||
@ -1326,12 +1309,14 @@ systemctl try-restart php-fpm.service >/dev/null 2>&1 || :
|
||||
%dir %{_datadir}/php/preload
|
||||
|
||||
%files help
|
||||
%defattr(-,root,root)
|
||||
%doc EXTENSIONS NEWS README* UPGRADING* *md docs
|
||||
%doc php-fpm.conf.default www.conf.default php.ini-*
|
||||
%{_mandir}/*
|
||||
%{_mandir}/man?/*
|
||||
|
||||
%changelog
|
||||
* Wed Jul 31 2024 Funda Wang <fundawang@yeah.net> - 8.3.10-1
|
||||
- New version 8.3.10
|
||||
|
||||
* Wed Jun 12 2024 Funda Wang <fundawang@yeah.net> - 8.3.8-2
|
||||
- Fix GH-14480 Method visibility issue introduced in version 8.3.8
|
||||
- Update licenses declaration
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user