mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-10 12:50:28 +01:00
28 lines
1.1 KiB
Diff
28 lines
1.1 KiB
Diff
From 1ef9c95d02515c643df7f8ac642186f4e81ade43 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 c3ff7a6b8f..a2af5b4b29 100644
|
|
--- a/src/main/java/net/minecraft/server/LoginListener.java
|
|
+++ b/src/main/java/net/minecraft/server/LoginListener.java
|
|
@@ -56,7 +56,11 @@ public class LoginListener implements PacketLoginInListener {
|
|
}
|
|
// Paper end
|
|
if (this.g == LoginListener.EnumProtocolState.READY_TO_ACCEPT) {
|
|
- this.c();
|
|
+ // Paper start - prevent logins to be processed even though disconnect was called
|
|
+ if (networkManager.isConnected()) {
|
|
+ this.c();
|
|
+ }
|
|
+ // Paper end
|
|
} else if (this.g == LoginListener.EnumProtocolState.DELAY_ACCEPT) {
|
|
EntityPlayer entityplayer = this.server.getPlayerList().a(this.i.getId());
|
|
|
|
--
|
|
2.22.0
|
|
|