From 578a4b479dfc9ba6342ef2dc366459043b4dbac0 Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20=E2=80=98Bombe=E2=80=99=20Roden?= Date: Mon, 27 Jan 2014 06:27:27 +0100 Subject: [PATCH] Reset line suppression when a command is received. --- src/main/java/net/pterodactylus/xdcc/ui/stdin/CommandReader.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/net/pterodactylus/xdcc/ui/stdin/CommandReader.java b/src/main/java/net/pterodactylus/xdcc/ui/stdin/CommandReader.java index e9bcc3c..016c9d0 100644 --- a/src/main/java/net/pterodactylus/xdcc/ui/stdin/CommandReader.java +++ b/src/main/java/net/pterodactylus/xdcc/ui/stdin/CommandReader.java @@ -63,7 +63,7 @@ public class CommandReader extends AbstractExecutionThreadService { private final BufferedReader reader; /** The writer to write the results to. */ - private final Writer writer; + private final DuplicateLineSuppressingWriter writer; private final Collection failedDownloads; /** @@ -110,6 +110,7 @@ public class CommandReader extends AbstractExecutionThreadService { if (line.equals("")) { line = lastLine; } + writer.reset(); String[] words = line.split(" +"); String commandName = words[0]; Collection eligibleCommands = findEligibleCommands(commandName); -- 2.7.4