aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorZach Brown <[email protected]>2016-11-28 15:57:17 -0600
committerZach Brown <[email protected]>2016-11-28 15:57:17 -0600
commit946bffb68d6a05e44075a5dc68fc3b6c248e8c1d (patch)
treee2a048692526b25eb4d1b7d33b44743522d42e5b
parent9410004c4416e7c7369683bf950e7d670a20f250 (diff)
downloadPaper-946bffb68d6a05e44075a5dc68fc3b6c248e8c1d.tar.gz
Paper-946bffb68d6a05e44075a5dc68fc3b6c248e8c1d.zip
Don't process packets from offline players
-rw-r--r--Spigot-Server-Patches/0184-Don-t-process-packets-from-offline-players.patch30
1 files changed, 30 insertions, 0 deletions
diff --git a/Spigot-Server-Patches/0184-Don-t-process-packets-from-offline-players.patch b/Spigot-Server-Patches/0184-Don-t-process-packets-from-offline-players.patch
new file mode 100644
index 0000000000..6ff3eb7e12
--- /dev/null
+++ b/Spigot-Server-Patches/0184-Don-t-process-packets-from-offline-players.patch
@@ -0,0 +1,30 @@
+From 87366b9912d670dc827854b9f83456f5f61cbef0 Mon Sep 17 00:00:00 2001
+From: From: Alfie Cleveland <[email protected]>
+Date: Mon, 28 Nov 2016 15:56:28 -0600
+Subject: [PATCH] Don't process packets from offline players
+
+
+diff --git a/src/main/java/net/minecraft/server/EntityHuman.java b/src/main/java/net/minecraft/server/EntityHuman.java
+index 301313b..865c1a2 100644
+--- a/src/main/java/net/minecraft/server/EntityHuman.java
++++ b/src/main/java/net/minecraft/server/EntityHuman.java
+@@ -14,6 +14,7 @@ import javax.annotation.Nullable;
+ // CraftBukkit start
+ import org.bukkit.craftbukkit.entity.CraftHumanEntity;
+ import org.bukkit.craftbukkit.entity.CraftItem;
++import org.bukkit.craftbukkit.entity.CraftPlayer; // Paper
+ import org.bukkit.craftbukkit.event.CraftEventFactory;
+ import org.bukkit.entity.Player;
+ import org.bukkit.event.entity.EntityCombustByEntityEvent;
+@@ -301,7 +302,7 @@ public abstract class EntityHuman extends EntityLiving {
+ }
+
+ protected boolean cj() {
+- return this.getHealth() <= 0.0F || this.isSleeping();
++ return this.getHealth() <= 0.0F || this.isSleeping() || (this.bukkitEntity != null && this.bukkitEntity instanceof CraftPlayer && !((CraftPlayer) this.bukkitEntity).isOnline()); // Paper - Pull #517
+ }
+
+ public void closeInventory() {
+--
+2.10.2
+