-
Notifications
You must be signed in to change notification settings - Fork 79
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove the world before nullifying chunkLoader & chunkProvider (#98)
- Loading branch information
Showing
2 changed files
with
35 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
1.8.8--2882919d66fc3bf050fe2a1474393750d281fa07 | ||
1.8.8--2f2122c04575618c76b2f485c1528480c02b5589 |
34 changes: 34 additions & 0 deletions
34
patches/server/0206-Remove-the-world-before-nullifying-chunkLoader-chunk.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
From a7addc1b58400190e483e0bc0cf4c02c2eccfff5 Mon Sep 17 00:00:00 2001 | ||
From: William Jeffcock <[email protected]> | ||
Date: Thu, 5 Aug 2021 19:17:47 +0100 | ||
Subject: [PATCH] Remove the world before nullifying chunkLoader & | ||
chunkProvider | ||
|
||
|
||
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java | ||
index 1a92092b..0f75111e 100644 | ||
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java | ||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java | ||
@@ -912,6 +912,9 @@ public final class CraftServer implements Server { | ||
return false; | ||
} | ||
|
||
+ worlds.remove(world.getName().toLowerCase()); | ||
+ console.worlds.remove(console.worlds.indexOf(handle)); | ||
+ | ||
if (save) { | ||
try { | ||
handle.save(true, null); | ||
@@ -937,9 +940,6 @@ public final class CraftServer implements Server { | ||
chunkProviderServer.chunks.clear(); | ||
} | ||
|
||
- worlds.remove(world.getName().toLowerCase()); | ||
- console.worlds.remove(console.worlds.indexOf(handle)); | ||
- | ||
File parentFolder = world.getWorldFolder().getAbsoluteFile(); | ||
|
||
// Synchronized because access to RegionFileCache.a is guarded by this lock. | ||
-- | ||
2.17.1 | ||
|