diff --git a/FightSystem_Main/src/de/steamwar/fightsystem/record/FileRecorder.java b/FightSystem_Main/src/de/steamwar/fightsystem/record/FileRecorder.java index 3a0c616..ff64aee 100644 --- a/FightSystem_Main/src/de/steamwar/fightsystem/record/FileRecorder.java +++ b/FightSystem_Main/src/de/steamwar/fightsystem/record/FileRecorder.java @@ -22,10 +22,7 @@ package de.steamwar.fightsystem.record; import org.bukkit.Bukkit; import org.bukkit.World; -import java.io.DataOutputStream; -import java.io.File; -import java.io.FileOutputStream; -import java.io.IOException; +import java.io.*; import java.util.logging.Level; import java.util.zip.GZIPOutputStream; @@ -39,7 +36,7 @@ public class FileRecorder extends Recorder { File file = new File(world.getWorldFolder(), world.getName() + ".recording"); try{ file.createNewFile(); - outputStream = new DataOutputStream(new GZIPOutputStream(new FileOutputStream(file), 4096)); + outputStream = new DataOutputStream(new BufferedOutputStream(new GZIPOutputStream(new FileOutputStream(file)), 4096)); }catch(IOException e){ throw new SecurityException("Could not open file", e); } @@ -127,12 +124,12 @@ public class FileRecorder extends Recorder { @Override protected void doFlush() { - try { + /*try { outputStream.flush(); } catch (IOException e) { Bukkit.getLogger().log(Level.SEVERE, "Could not flush", e); close(); - } + }*/ } @Override