From 5736cdc559b3fb9732f432e70c5a0c4da576290c Mon Sep 17 00:00:00 2001 From: md_5 Date: Sat, 27 Apr 2019 21:33:07 +1000 Subject: [PATCH] Intermittent hang on /stop --- nms-patches/PlayerConnectionUtils.patch | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nms-patches/PlayerConnectionUtils.patch b/nms-patches/PlayerConnectionUtils.patch index 87aa731f40..3fe05f31aa 100644 --- a/nms-patches/PlayerConnectionUtils.patch +++ b/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;