From f040900d3c8ee961ef1bb2b6af9a6c8cd42c197d Mon Sep 17 00:00:00 2001 From: Dinnerbone Date: Wed, 9 Mar 2011 23:34:26 +0000 Subject: [PATCH] Attempt to fix console crash --- .../org/bukkit/craftbukkit/util/TerminalConsoleHandler.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/main/java/org/bukkit/craftbukkit/util/TerminalConsoleHandler.java b/src/main/java/org/bukkit/craftbukkit/util/TerminalConsoleHandler.java index 2034ad972f..43bc392f3d 100644 --- a/src/main/java/org/bukkit/craftbukkit/util/TerminalConsoleHandler.java +++ b/src/main/java/org/bukkit/craftbukkit/util/TerminalConsoleHandler.java @@ -20,7 +20,11 @@ public class TerminalConsoleHandler extends ConsoleHandler { reader.printString(ConsoleReader.RESET_LINE + ""); reader.flushConsole(); super.flush(); - reader.drawLine(); + try { + reader.drawLine(); + } catch (Throwable ex) { + reader.getCursorBuffer().clearBuffer(); + } reader.flushConsole(); } catch (IOException ex) { Logger.getLogger(TerminalConsoleHandler.class.getName()).log(Level.SEVERE, null, ex);