mirror of
https://github.com/PaperMC/Waterfall.git
synced 2024-11-24 19:25:16 +01:00
b5d048b57a
Not worth the time wasted on closing invalid bug reports.
32 lines
1.7 KiB
Diff
32 lines
1.7 KiB
Diff
From f6c48a227b9dc70d97ee9c22f54d0481913535fb Mon Sep 17 00:00:00 2001
|
|
From: Techcable <Techcable@techcable.net>
|
|
Date: Mon, 6 Jun 2016 13:36:10 -0600
|
|
Subject: [PATCH] Don't send KICK packets while in HANDSHAKE state
|
|
|
|
|
|
diff --git a/proxy/src/main/java/net/md_5/bungee/connection/InitialHandler.java b/proxy/src/main/java/net/md_5/bungee/connection/InitialHandler.java
|
|
index bf450f98..9e501c00 100644
|
|
--- a/proxy/src/main/java/net/md_5/bungee/connection/InitialHandler.java
|
|
+++ b/proxy/src/main/java/net/md_5/bungee/connection/InitialHandler.java
|
|
@@ -266,7 +266,7 @@ public class InitialHandler extends PacketHandler implements PendingConnection
|
|
this.handshake = handshake;
|
|
ch.setVersion( handshake.getProtocolVersion() );
|
|
|
|
- // Starting with FML 1.8, a "\0FML\0" token is appended to the handshake. This interferes
|
|
+ // Starting with FML 1.8, a "\0FML\0" token is appended to the handshake. This interferes
|
|
// with Bungee's IP forwarding, so we detect it, and remove it from the host string, for now.
|
|
// We know FML appends \00FML\00. However, we need to also consider that other systems might
|
|
// add their own data to the end of the string. So, we just take everything from the \0 character
|
|
@@ -547,7 +547,7 @@ public class InitialHandler extends PacketHandler implements PendingConnection
|
|
@Override
|
|
public void disconnect(final BaseComponent... reason)
|
|
{
|
|
- if ( thisState != State.STATUS && thisState != State.PING )
|
|
+ if ( thisState != State.STATUS && thisState != State.PING && thisState != State.HANDSHAKE ) // Waterfall: Don't kick during handshake
|
|
{
|
|
ch.delayedClose( new Kick( ComponentSerializer.toString( reason ) ) );
|
|
} else
|
|
--
|
|
2.14.1
|
|
|