mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-28 23:38:25 +01:00
Fix Reloadable save players error on stop
Not sure what plugins or panels are doing to have triggered this. Reloading resource packs appear to have been happening during shutdown So this will abort the end of the reload process if we are not on the correct thread and stop saving players as part of this task too.
This commit is contained in:
parent
b15e37b0e9
commit
52496b075b
1 changed files with 10 additions and 0 deletions
|
@ -260,6 +260,16 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
|||
throw new RuntimeException("Error generating crash report", t);
|
||||
}
|
||||
// Spigot End
|
||||
@@ -0,0 +0,0 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
this.resourcePackRepository.a(collection);
|
||||
this.saveData.a(a(this.resourcePackRepository));
|
||||
datapackresources.i();
|
||||
- this.getPlayerList().savePlayers();
|
||||
+ if (Thread.currentThread() != this.serverThread) return; // Paper
|
||||
+ //this.getPlayerList().savePlayers(); // Paper - we don't need to do this
|
||||
this.getPlayerList().reload();
|
||||
this.customFunctionData.a(this.dataPackResources.a());
|
||||
this.ak.a(this.dataPackResources.h());
|
||||
diff --git a/src/main/java/net/minecraft/server/PlayerChunkMap.java b/src/main/java/net/minecraft/server/PlayerChunkMap.java
|
||||
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
||||
--- a/src/main/java/net/minecraft/server/PlayerChunkMap.java
|
||||
|
|
Loading…
Reference in a new issue