Mirror von
https://github.com/PaperMC/Paper.git
synchronisiert 2024-11-15 12:30:06 +01:00
Ursprung
47a42deb01
Commit
0e7932315b
22
Spigot-Server-Patches/0339-Fix-NPE-Potential-in-CraftBanner.patch
Normale Datei
22
Spigot-Server-Patches/0339-Fix-NPE-Potential-in-CraftBanner.patch
Normale Datei
@ -0,0 +1,22 @@
|
||||
From 334b744d30a8992b3facf63bb4da6339d85345f0 Mon Sep 17 00:00:00 2001
|
||||
From: Aikar <aikar@aikar.co>
|
||||
Date: Wed, 15 Aug 2018 08:46:20 -0400
|
||||
Subject: [PATCH] Fix NPE Potential in CraftBanner
|
||||
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBanner.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBanner.java
|
||||
index 4332a03a41..4488321017 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/block/CraftBanner.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBanner.java
|
||||
@@ -30,7 +30,7 @@ public class CraftBanner extends CraftBlockEntityState<TileEntityBanner> impleme
|
||||
public void load(TileEntityBanner banner) {
|
||||
super.load(banner);
|
||||
|
||||
- base = DyeColor.getByWoolData((byte) banner.color.getColorIndex());
|
||||
+ base = banner.color != null ? DyeColor.getByWoolData((byte) banner.color.getColorIndex()) : null; // Paper
|
||||
patterns = new ArrayList<Pattern>();
|
||||
|
||||
if (banner.patterns != null) {
|
||||
--
|
||||
2.18.0
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren