From 1b583b25a9ea5868b234b32001c48eb23179a493 Mon Sep 17 00:00:00 2001 From: Aikar Date: Sat, 23 Feb 2019 16:18:46 -0500 Subject: [PATCH] Missed diff on spigot chunk patch not much concern over it, it would of just misidentified a corrupt chunk as not corrupt --- .../Allow-Saving-of-Oversized-Chunks.patch | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/Spigot-Server-Patches/Allow-Saving-of-Oversized-Chunks.patch b/Spigot-Server-Patches/Allow-Saving-of-Oversized-Chunks.patch index 55cdf3b79d..418428dd7a 100644 --- a/Spigot-Server-Patches/Allow-Saving-of-Oversized-Chunks.patch +++ b/Spigot-Server-Patches/Allow-Saving-of-Oversized-Chunks.patch @@ -51,7 +51,7 @@ index 12268f87b9..e1f7e06ab2 100644 a((NBTBase) nbttagcompound, dataoutput); } diff --git a/src/main/java/net/minecraft/server/RegionFile.java b/src/main/java/net/minecraft/server/RegionFile.java -index c20511588d..448a903c16 100644 +index c20511588d..d148ce4976 100644 --- a/src/main/java/net/minecraft/server/RegionFile.java +++ b/src/main/java/net/minecraft/server/RegionFile.java @@ -0,0 +0,0 @@ public class RegionFile { @@ -62,6 +62,15 @@ index c20511588d..448a903c16 100644 // Paper End for (j = 0; j < 1024; ++j) { +@@ -0,0 +0,0 @@ public class RegionFile { + this.c.seek(j * 4 + 4); // Go back to where we were + } + } +- if (k > 0 && (k >> 8) > 1 && (k >> 8) + (k & 255) <= this.f.size()) { // Paper >= 1 as 0/1 are the headers, and negative isnt valid ++ if (k > 0 && (k >> 8) > 1 && (k >> 8) + (length) <= this.f.size()) { // Paper >= 1 as 0/1 are the headers, and negative isnt valid + for (int l = 0; l < (length); ++l) { + // Spigot end + this.f.set((k >> 8) + l, false); @@ -0,0 +0,0 @@ public class RegionFile { }