Paper/Spigot-Server-Patches/0247-Prevent-logins-from-being-processed-when-the-player-.patch
Zach Brown 6f2009754d
Stop explicitly blocking Vanilla Method Profiler
At the time this was re-added, there was concern around how the JIT
would handle the system property that enabled it.

This shouldn't be a problem, and as such we no longer need to block
access to it.

The Vanilla Method Profiler will not provide much to most users however
there is no harm in providing it as an option. For most users, the
recommended and supported method for determining performance issues with
Paper will continue to be Timings.
2018-03-31 14:55:42 -04:00

28 lines
1.1 KiB
Diff

From 138b8d9ad24d25d198ec0904bc556ebdea9cdd36 Mon Sep 17 00:00:00 2001
From: killme <killme-git@ibts.me>
Date: Sun, 12 Nov 2017 19:40:01 +0100
Subject: [PATCH] Prevent logins from being processed when the player has
disconnected
diff --git a/src/main/java/net/minecraft/server/LoginListener.java b/src/main/java/net/minecraft/server/LoginListener.java
index 75df9283..eaac25dc 100644
--- a/src/main/java/net/minecraft/server/LoginListener.java
+++ b/src/main/java/net/minecraft/server/LoginListener.java
@@ -60,7 +60,11 @@ public class LoginListener implements PacketLoginInListener, ITickable {
}
// Paper end
if (this.g == LoginListener.EnumProtocolState.READY_TO_ACCEPT) {
- this.b();
+ // Paper start - prevent logins to be processed even though disconnect was called
+ if (networkManager.isConnected()) {
+ this.b();
+ }
+ // Paper end
} else if (this.g == LoginListener.EnumProtocolState.DELAY_ACCEPT) {
EntityPlayer entityplayer = this.server.getPlayerList().a(this.i.getId());
--
2.14.3