SteamWar/SpigotCore
Archiviert
13
0

Fix mark support with buffering
Alle Prüfungen waren erfolgreich
SteamWarCI Build successful

Dieser Commit ist enthalten in:
Lixfel 2023-08-30 12:45:24 +02:00
Ursprung 4020b69860
Commit 311bb09a19

Datei anzeigen

@ -25,6 +25,7 @@ import com.sk89q.worldedit.extent.clipboard.Clipboard;
import com.sk89q.worldedit.extent.clipboard.io.MCEditSchematicReader; import com.sk89q.worldedit.extent.clipboard.io.MCEditSchematicReader;
import de.steamwar.sql.NoClipboardException; import de.steamwar.sql.NoClipboardException;
import java.io.BufferedInputStream;
import java.io.IOException; import java.io.IOException;
import java.io.InputStream; import java.io.InputStream;
@ -34,7 +35,7 @@ public class WorldEditWrapper18 extends WorldEditWrapper14 {
@SuppressWarnings("removal") @SuppressWarnings("removal")
public Clipboard getClipboard(InputStream is, boolean schemFormat) throws IOException { public Clipboard getClipboard(InputStream is, boolean schemFormat) throws IOException {
//Use FAWE reader due to FAWE capability of reading corrupt FAWE schems //Use FAWE reader due to FAWE capability of reading corrupt FAWE schems
NBTInputStream nbtStream = new NBTInputStream(is); NBTInputStream nbtStream = new NBTInputStream(new BufferedInputStream(is));
try { try {
return (schemFormat ? new FastSchematicReader(nbtStream) : new MCEditSchematicReader(nbtStream)).read(); return (schemFormat ? new FastSchematicReader(nbtStream) : new MCEditSchematicReader(nbtStream)).read();
} catch (NullPointerException e) { } catch (NullPointerException e) {