Updated Upstream (Bukkit/CraftBukkit/Spigot) (#6990)

This commit is contained in:
Jake Potrebic
2021-12-02 12:21:33 -08:00
parent 0f7314ee80
commit 57c673412d
7 changed files with 15 additions and 14 deletions

View File

@@ -37,12 +37,13 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
+ handledByEvent = true; // Hooray, we did it!
+ }
+ }
+ // Don't try and handle default logic if it's been handled by the event.
+ if (!handledByEvent && proxyLogicEnabled) {
+ // Paper end
// Spigot Start
String[] split = packet.hostName.split("\00");
- if (org.spigotmc.SpigotConfig.bungee) {
+ //if (org.spigotmc.SpigotConfig.bungee) { // Paper - comment out, we check above!
String[] split = packet.hostName.split("\00");
+ // Don't try and handle default logic if it's been handled by the event.
+ if (!handledByEvent && proxyLogicEnabled) {
+ // Paper end
+ // if (org.spigotmc.SpigotConfig.bungee) { // Paper - comment out, we check above!
if ( ( split.length == 3 || split.length == 4 ) && ( ServerHandshakePacketListenerImpl.HOST_PATTERN.matcher( split[1] ).matches() ) ) {
packet.hostName = split[0];
connection.address = new java.net.InetSocketAddress(split[1], ((java.net.InetSocketAddress) this.connection.getRemoteAddress()).getPort());