Updated Upstream (Waterfall)

Upstream has released updates that appears to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing

Waterfall Changes:
3a8916d Remove version from brand info (Fixes #517)
This commit is contained in:
Shane Freeder 2020-06-20 18:31:12 +01:00
parent 1f3c21d104
commit 726a927792
No known key found for this signature in database
GPG Key ID: A3F61EA5A085289C
2 changed files with 21 additions and 13 deletions

@ -1 +1 @@
Subproject commit 33c73f9d3d3aa31b48ec2bf06fb861aaa15bd1e6
Subproject commit 3a8916d9a3e38e95cb0a77dbe079bafe9c3d8c54

View File

@ -1,4 +1,4 @@
From 8e6239a685eddd12d83bab91215bf21771d85499 Mon Sep 17 00:00:00 2001
From d43a7b391cd61eef81f3d43e41f5d2613291ec2a Mon Sep 17 00:00:00 2001
From: Troy Frew <fuzzy_bot@arenaga.me>
Date: Tue, 15 Nov 2016 10:31:04 -0500
Subject: [PATCH] 1.7.x Protocol Patch
@ -1127,7 +1127,7 @@ index 0b27fc86b..74066702c 100644
public void write(ByteBuf buf, ProtocolConstants.Direction direction, int protocolVersion)
{
diff --git a/protocol/src/main/java/net/md_5/bungee/protocol/packet/TabCompleteRequest.java b/protocol/src/main/java/net/md_5/bungee/protocol/packet/TabCompleteRequest.java
index fca4c5d2c..25d167510 100644
index 27b232dcb..6c2cef1ee 100644
--- a/protocol/src/main/java/net/md_5/bungee/protocol/packet/TabCompleteRequest.java
+++ b/protocol/src/main/java/net/md_5/bungee/protocol/packet/TabCompleteRequest.java
@@ -1,5 +1,6 @@
@ -1469,10 +1469,18 @@ index 87cff4ffc..4891ec28b 100644
{
this.compressionThreshold = compressionThreshold;
diff --git a/proxy/src/main/java/net/md_5/bungee/connection/DownstreamBridge.java b/proxy/src/main/java/net/md_5/bungee/connection/DownstreamBridge.java
index d7d0fafcb..21597768e 100644
index daac86045..5fbc61a9f 100644
--- a/proxy/src/main/java/net/md_5/bungee/connection/DownstreamBridge.java
+++ b/proxy/src/main/java/net/md_5/bungee/connection/DownstreamBridge.java
@@ -167,7 +167,7 @@ public class DownstreamBridge extends PacketHandler
@@ -20,6 +20,7 @@ import io.netty.buffer.Unpooled;
import io.netty.channel.unix.DomainSocketAddress;
import java.io.DataInput;
import java.net.InetSocketAddress;
+import java.nio.charset.StandardCharsets; // Waterfall
import java.util.ArrayList;
import java.util.HashMap; // Waterfall
import java.util.List;
@@ -167,7 +168,7 @@ public class DownstreamBridge extends PacketHandler
switch ( objective.getAction() )
{
case 0:
@ -1481,7 +1489,7 @@ index d7d0fafcb..21597768e 100644
break;
case 1:
serverScoreboard.removeObjective( objective.getName() );
@@ -177,7 +177,7 @@ public class DownstreamBridge extends PacketHandler
@@ -177,7 +178,7 @@ public class DownstreamBridge extends PacketHandler
if ( oldObjective != null )
{
oldObjective.setValue( objective.getValue() );
@ -1490,7 +1498,7 @@ index d7d0fafcb..21597768e 100644
}
break;
default:
@@ -274,16 +274,28 @@ public class DownstreamBridge extends PacketHandler
@@ -274,16 +275,28 @@ public class DownstreamBridge extends PacketHandler
if ( pluginMessage.getTag().equals( con.getPendingConnection().getVersion() >= ProtocolConstants.MINECRAFT_1_13 ? "minecraft:brand" : "MC|Brand" ) )
{
@ -1501,7 +1509,7 @@ index d7d0fafcb..21597768e 100644
- Preconditions.checkState( !serverBrand.contains( bungee.getName() ), "Cannot connect proxy to itself!" );
-
- brand = ByteBufAllocator.DEFAULT.heapBuffer();
- DefinedPacket.writeString( bungee.getName() + " (" + bungee.getVersion() + ")" + " <- " + serverBrand, brand );
- DefinedPacket.writeString( bungee.getName() + " <- " + serverBrand, brand ); // Waterfall
- pluginMessage.setData( brand );
- brand.release();
+ // Travertine start
@ -1513,7 +1521,7 @@ index d7d0fafcb..21597768e 100644
+ String serverBrand = DefinedPacket.readString(brand);
+ brand.release();
+ brand = ByteBufAllocator.DEFAULT.heapBuffer();
+ DefinedPacket.writeString(bungee.getName() + " (" + bungee.getVersion() + ")" + " <- " + serverBrand, brand);
+ DefinedPacket.writeString(bungee.getName() + " <- " + serverBrand, brand ); // Waterfall
+ pluginMessage.setData(brand);
+ brand.release();
+ } catch (Exception ProtocolHacksSuck)
@ -1522,8 +1530,8 @@ index d7d0fafcb..21597768e 100644
+ }
+ } else
+ {
+ String serverBrand = new String( pluginMessage.getData(), "UTF-8" );
+ pluginMessage.setData( ( bungee.getName() + " (" + bungee.getVersion() + ")" + " <- " + serverBrand ).getBytes( "UTF-8" ) );
+ String serverBrand = new String( pluginMessage.getData(), StandardCharsets.UTF_8);
+ pluginMessage.setData( ( bungee.getName() + " <- " + serverBrand ).getBytes(StandardCharsets.UTF_8) ); // Travertine
+ }
+ // Travertine end
// changes in the packet are ignored so we need to send it manually
@ -1617,7 +1625,7 @@ index 6df3f3dd9..6cd71071e 100644
( (BungeeServerInfo) target ).cachePing( serverPing );
callback.done( serverPing, null );
diff --git a/proxy/src/main/java/net/md_5/bungee/connection/UpstreamBridge.java b/proxy/src/main/java/net/md_5/bungee/connection/UpstreamBridge.java
index 4d8bac5d1..359c90e07 100644
index 7913d40cc..0994bebd9 100644
--- a/proxy/src/main/java/net/md_5/bungee/connection/UpstreamBridge.java
+++ b/proxy/src/main/java/net/md_5/bungee/connection/UpstreamBridge.java
@@ -84,7 +84,12 @@ public class UpstreamBridge extends PacketHandler
@ -2004,5 +2012,5 @@ index daf12f74e..e33861abb 100644
@Override
--
2.26.2
2.27.0