From 7b8040de67df77b6b762e3516f7ea68b66e2913f Mon Sep 17 00:00:00 2001 From: nsfisis Date: Mon, 13 Jan 2025 21:42:23 +0900 Subject: [PATCH 1/3] =?UTF-8?q?[PHP=208.4]=20unserialize()=20can=20throw?= =?UTF-8?q?=20a=20ValueError=20and=20TypeError=20=E3=82=92=E5=8F=96?= =?UTF-8?q?=E3=82=8A=E8=BE=BC=E3=81=BF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- reference/var/functions/unserialize.xml | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/reference/var/functions/unserialize.xml b/reference/var/functions/unserialize.xml index 7ac4859042..596968ea3d 100644 --- a/reference/var/functions/unserialize.xml +++ b/reference/var/functions/unserialize.xml @@ -1,6 +1,6 @@ - + @@ -145,10 +145,16 @@ &reftitle.errors; - + オブジェクトは、 アンシリアライズを実行するハンドラで Throwable をスローしても構いません。 - + + + PHP 8.4.0 以降では、optionsallowed_classes 要素が + クラス名の array でない場合、 + unserializeTypeError と + ValueError をスローします。 + @@ -157,6 +163,15 @@ + + 8.4.0 + + optionsallowed_classes 要素が + クラス名の array でない場合、 + TypeErrorValueError を + スローするようになりました。 + + &Version; &Description; From 58383184547eb3bdac7399b31778c0df11e89cc0 Mon Sep 17 00:00:00 2001 From: nsfisis Date: Mon, 13 Jan 2025 21:44:51 +0900 Subject: [PATCH 2/3] =?UTF-8?q?unserialize.xml=20Specify=20a=20strict=20ty?= =?UTF-8?q?pe=20for=20the=20allowed=5Fclasses=20element=20=E3=82=92?= =?UTF-8?q?=E5=8F=96=E3=82=8A=E8=BE=BC=E3=81=BF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- reference/var/functions/unserialize.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/reference/var/functions/unserialize.xml b/reference/var/functions/unserialize.xml index 596968ea3d..47bc0746d7 100644 --- a/reference/var/functions/unserialize.xml +++ b/reference/var/functions/unserialize.xml @@ -1,6 +1,6 @@ - + @@ -90,7 +90,7 @@ allowed_classes - mixed + array|bool 受け付けるクラス名の配列を指定します。あらゆるクラスを拒否する場合は From 7692b0b9b5716e20405ba28c938835e3c33ae06b Mon Sep 17 00:00:00 2001 From: nsfisis Date: Mon, 13 Jan 2025 21:46:19 +0900 Subject: [PATCH 3/3] =?UTF-8?q?Fix=20table=20error=20=E3=82=92=E5=8F=96?= =?UTF-8?q?=E3=82=8A=E8=BE=BC=E3=81=BF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- reference/var/functions/unserialize.xml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/reference/var/functions/unserialize.xml b/reference/var/functions/unserialize.xml index 47bc0746d7..296014e9b3 100644 --- a/reference/var/functions/unserialize.xml +++ b/reference/var/functions/unserialize.xml @@ -1,6 +1,6 @@ - + @@ -163,6 +163,12 @@ + + &Version; + &Description; + + + 8.4.0 @@ -172,12 +178,6 @@ スローするようになりました。 - - &Version; - &Description; - - - 8.3.0