summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/main/java/net/minecraft/server/MinecraftServer.java6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
index c6710622..c1c4aa06 100644
--- a/src/main/java/net/minecraft/server/MinecraftServer.java
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java
@@ -113,6 +113,12 @@ public abstract class MinecraftServer implements ICommandListener, Runnable, IMo
// CraftBukkit start
this.options = options;
+ // Try to see if we're actually running in a terminal, disable jline if not
+ if (System.console() == null) {
+ System.setProperty("jline.terminal", "jline.UnsupportedTerminal");
+ org.bukkit.craftbukkit.Main.useJline = false;
+ }
+
try {
this.reader = new ConsoleReader(System.in, System.out);
this.reader.setExpandEvents(false); // Avoid parsing exceptions for uncommonly used event designators