From 78602f07ffe94c656fe83c9ce4991838c61c7674 Mon Sep 17 00:00:00 2001 From: CraftBukkit/Spigot Date: Sat, 27 Apr 2019 21:33:07 +1000 Subject: [PATCH] Intermittent hang on /stop By: md_5 --- paper-server/nms-patches/PlayerConnectionUtils.patch | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/paper-server/nms-patches/PlayerConnectionUtils.patch b/paper-server/nms-patches/PlayerConnectionUtils.patch index 87aa731f40..3fe05f31aa 100644 --- a/paper-server/nms-patches/PlayerConnectionUtils.patch +++ b/paper-server/nms-patches/PlayerConnectionUtils.patch @@ -4,7 +4,7 @@ public static void ensureMainThread(Packet packet, T t0, IAsyncTaskHandler iasynctaskhandler) throws CancelledPacketHandleException { if (!iasynctaskhandler.isMainThread()) { iasynctaskhandler.execute(() -> { -+ if (t0 instanceof PlayerConnection && ((PlayerConnection) t0).processedDisconnect) return; // CraftBukkit ++ if (MinecraftServer.getServer().isStopped() || (t0 instanceof PlayerConnection && ((PlayerConnection) t0).processedDisconnect)) return; // CraftBukkit, MC-142590 packet.a(t0); }); throw CancelledPacketHandleException.INSTANCE;