From 2ef7a0fb6018fe5834d1cb300b1efe2f1106dd11 Mon Sep 17 00:00:00 2001
From: "J. Peter M. Schuler" <j.peter.m.schuler@uni-due.de>
Date: Wed, 16 Nov 2022 10:57:07 +0100
Subject: [PATCH] [BUGFIX] Avoid undefined array key "pointer." in
 AbstractPlugin
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Resolves: #99106
Releases: main, 11.5
Change-Id: Iabddf0b2f1c98db6e3e07f26162257f696d6fd9f
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/76642
Tested-by: core-ci <typo3@b13.com>
Reviewed-by: Oliver Klee <typo3-coding@oliverklee.de>
Tested-by: Christian Kuhn <lolli@schwarzbu.ch>
Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch>
Tested-by: Stefan Bürk <stefan@buerk.tech>
Reviewed-by: Stefan Bürk <stefan@buerk.tech>
---
 typo3/sysext/frontend/Classes/Plugin/AbstractPlugin.php | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/typo3/sysext/frontend/Classes/Plugin/AbstractPlugin.php b/typo3/sysext/frontend/Classes/Plugin/AbstractPlugin.php
index 742db17dc778..14065e057ff8 100644
--- a/typo3/sysext/frontend/Classes/Plugin/AbstractPlugin.php
+++ b/typo3/sysext/frontend/Classes/Plugin/AbstractPlugin.php
@@ -578,7 +578,7 @@ class AbstractPlugin
         'activeLinkWrap' => '<span class="activeLinkWrap">|</span>'
         );*/
         // Initializing variables:
-        $pointer = (int)$this->piVars[$pointerName];
+        $pointer = (int)($this->piVars[$pointerName] ?? 0);
         $count = (int)$this->internal['res_count'];
         $results_at_a_time = MathUtility::forceIntegerInRange($this->internal['results_at_a_time'], 1, 1000);
         $totalPages = (int)ceil($count / $results_at_a_time);
-- 
GitLab