Waterfall/BungeeCord-Patches/0014-Enable-TCP_NODELAY.patch
_tomcraft c40d7af454
Updated Upstream (BungeeCord) (#731)
Co-authored-by: Thomas A <thomas.a@erisium.com>
2022-03-21 14:08:26 +00:00

23 lines
964 B
Diff

From 9a4d153e6af0749088ef8668c8293d5b469cb020 Mon Sep 17 00:00:00 2001
From: Harry <me@harry5573.uk>
Date: Sun, 24 Jan 2016 15:13:29 -0700
Subject: [PATCH] Enable TCP_NODELAY.
This is enabled by default on CraftBukkit/Spigot >= 1.8 and may help with network performance.
diff --git a/proxy/src/main/java/net/md_5/bungee/netty/PipelineUtils.java b/proxy/src/main/java/net/md_5/bungee/netty/PipelineUtils.java
index 61165e43..2d373660 100644
--- a/proxy/src/main/java/net/md_5/bungee/netty/PipelineUtils.java
+++ b/proxy/src/main/java/net/md_5/bungee/netty/PipelineUtils.java
@@ -165,6 +165,7 @@ public class PipelineUtils
{
// IP_TOS is not supported (Windows XP / Windows Server 2003)
}
+ ch.config().setOption( ChannelOption.TCP_NODELAY, true );
ch.config().setAllocator( PooledByteBufAllocator.DEFAULT );
ch.config().setWriteBufferWaterMark( MARK );
--
2.32.0 (Apple Git-132)