Archiviert
13
0
Dieses Repository wurde am 2021-12-14 archiviert. Du kannst Dateien ansehen und es klonen, aber nicht pushen oder Issues/Pull-Requests öffnen.
SteamSpigot/Spigot/SteamWar-Patches/Dont_write_unwritable_json_files_spigot.patch
2021-04-12 19:54:42 +02:00

19 Zeilen
785 B
Diff

Index: src/main/java/net/minecraft/server/JsonList.java
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
diff --git a/src/main/java/net/minecraft/server/JsonList.java b/src/main/java/net/minecraft/server/JsonList.java
--- a/src/main/java/net/minecraft/server/JsonList.java (revision ec1b4311cebfd9bc35a5f84f56df46cf7319649a)
+++ b/src/main/java/net/minecraft/server/JsonList.java (date 1609013366119)
@@ -156,6 +156,9 @@
}
public void save() throws IOException {
+ if(!this.c.canWrite())
+ return;
+
Collection<V> collection = this.d.values();
String s = this.b.toJson(collection);
BufferedWriter bufferedwriter = null;