Mirror von
https://github.com/PaperMC/Paper.git
synchronisiert 2024-11-15 12:30:06 +01:00
0708fa363b
Upstream has released updates that appears to apply and compile correctly. This update has not been tested by PaperMC and as with ANY update, please do your own testing CraftBukkit Changes:eb2e6578
SPIGOT-5116: Fix concurrent modification exception inside ChunkMapDistance989f9b3d
SPIGOT-4849: Fix server crash when accessing chunks during chunk load/unload/populate eventsf554183c
SPIGOT-5171: Don't fire PlayerTeleportEvent if not actually moving2349feb8
SPIGOT-5163: Cancelling PlayerBucketFillEvent visually removes the targeted block Spigot Changes: 9a643a6a Remove DataWatcher Locking
30 Zeilen
1.1 KiB
Diff
30 Zeilen
1.1 KiB
Diff
From 7b82841465226946c7984c2825385fe912d96c59 Mon Sep 17 00:00:00 2001
|
|
From: Aikar <aikar@aikar.co>
|
|
Date: Sat, 7 Jan 2017 15:41:58 -0500
|
|
Subject: [PATCH] Enforce Sync Player Saves
|
|
|
|
Saving players async is extremely dangerous. This will force it to main
|
|
the same way we handle async chunk loads.
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/PlayerList.java b/src/main/java/net/minecraft/server/PlayerList.java
|
|
index ee5297dc3..ccf8b7c70 100644
|
|
--- a/src/main/java/net/minecraft/server/PlayerList.java
|
|
+++ b/src/main/java/net/minecraft/server/PlayerList.java
|
|
@@ -930,11 +930,13 @@ public abstract class PlayerList {
|
|
}
|
|
|
|
public void savePlayers() {
|
|
+ MCUtil.ensureMain("Save Players" , () -> { // Paper - Ensure main
|
|
MinecraftTimings.savePlayers.startTiming(); // Paper
|
|
for (int i = 0; i < this.players.size(); ++i) {
|
|
this.savePlayerFile((EntityPlayer) this.players.get(i));
|
|
}
|
|
MinecraftTimings.savePlayers.stopTiming(); // Paper
|
|
+ return null; }); // Paper - ensure main
|
|
}
|
|
|
|
public WhiteList getWhitelist() {
|
|
--
|
|
2.22.0
|
|
|