From 12cd6c0ddfa8141b60e056359d28d26cd7b268a6 Mon Sep 17 00:00:00 2001 From: Sylvain Legrand Date: Mon, 20 Feb 2023 18:44:36 +0100 Subject: [PATCH] Fix tcpdi_parser infinite loop When mergin some old PDF we may have an infinite loop with this warning : "PHP Warning: Illegal string offset 'Type' in ./htdocs/includes/tcpdi/tcpdi_parser.php on line 706" --- htdocs/includes/tcpdi/tcpdi_parser.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/htdocs/includes/tcpdi/tcpdi_parser.php b/htdocs/includes/tcpdi/tcpdi_parser.php index 174c496d4f4..ef4162d5f4f 100644 --- a/htdocs/includes/tcpdi/tcpdi_parser.php +++ b/htdocs/includes/tcpdi/tcpdi_parser.php @@ -715,8 +715,7 @@ class tcpdi_parser { $next = strcspn($data, "\r\n", $offset); if ($next > 0) { $offset += $next; - list($obj, $unused) = $this->getRawObject($offset, $data); - return $obj; + return $this->getRawObject($offset, $data); } break; }