From 3e9902408fecc9a05028d864ee62439360736e94 Mon Sep 17 00:00:00 2001 From: zhangskz Date: Mon, 5 Feb 2024 17:20:19 -0500 Subject: [PATCH] Don't break the trace (#11311) (#15727) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Closes #11311 COPYBARA_INTEGRATE_REVIEW=https://github.com/protocolbuffers/protobuf/pull/11311 from umpirsky:patch-1 d280be57b71c32bdc255576aed06e400b07ce506 PiperOrigin-RevId: 603963886 Co-authored-by: Saša Stamenković --- php/src/Google/Protobuf/Internal/Message.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/php/src/Google/Protobuf/Internal/Message.php b/php/src/Google/Protobuf/Internal/Message.php index a427e4889f67..21d9c980e08b 100644 --- a/php/src/Google/Protobuf/Internal/Message.php +++ b/php/src/Google/Protobuf/Internal/Message.php @@ -1314,7 +1314,7 @@ public function parseFromJsonStream($input, $ignore_unknown) try { $this->mergeFromJsonArray($array, $ignore_unknown); } catch (\Exception $e) { - throw new GPBDecodeException($e->getMessage()); + throw new GPBDecodeException($e->getMessage(), $e->getCode(), $e); } }