From 0d2a5216f650cb58a77d1ef1d0ef3aaa7b6d5382 Mon Sep 17 00:00:00 2001 From: Nassim Jahnke Date: Fri, 3 Nov 2023 14:49:55 +1000 Subject: [PATCH] Add another slot sanity check --- patches/server/Add-slot-sanity-checks-in-container-clicks.patch | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/patches/server/Add-slot-sanity-checks-in-container-clicks.patch b/patches/server/Add-slot-sanity-checks-in-container-clicks.patch index 41a447084b..960ee217a0 100644 --- a/patches/server/Add-slot-sanity-checks-in-container-clicks.patch +++ b/patches/server/Add-slot-sanity-checks-in-container-clicks.patch @@ -20,7 +20,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 int j2; if (actionType == ClickType.SWAP) { -+ if (slotIndex < 0) return; // Paper ++ if (slotIndex < 0 || button < 0) return; // Paper slot2 = (Slot) this.slots.get(slotIndex); itemstack1 = playerinventory.getItem(button); itemstack = slot2.getItem();