From 503a853acad49ac6da7f520c26b3b27942dbfec5 Mon Sep 17 00:00:00 2001 From: James Moger <james.moger@gitblit.com> Date: Thu, 10 Apr 2014 18:58:08 -0400 Subject: [PATCH] Merge AbstractSshCommand and BaseCommand into a single class --- src/main/java/com/gitblit/transport/ssh/commands/SshCommand.java | 40 ++++++++++++++++++++-------------------- 1 files changed, 20 insertions(+), 20 deletions(-) diff --git a/src/main/java/com/gitblit/transport/ssh/commands/SshCommand.java b/src/main/java/com/gitblit/transport/ssh/commands/SshCommand.java index 44618f3..ee464e7 100644 --- a/src/main/java/com/gitblit/transport/ssh/commands/SshCommand.java +++ b/src/main/java/com/gitblit/transport/ssh/commands/SshCommand.java @@ -20,26 +20,26 @@ import org.apache.sshd.server.Environment; public abstract class SshCommand extends BaseCommand { - protected PrintWriter stdout; - protected PrintWriter stderr; + protected PrintWriter stdout; + protected PrintWriter stderr; - @Override - public void start(Environment env) throws IOException { - startThread(new CommandRunnable() { - @Override - public void run() throws Exception { - parseCommandLine(); - stdout = toPrintWriter(out); - stderr = toPrintWriter(err); - try { - SshCommand.this.run(); - } finally { - stdout.flush(); - stderr.flush(); - } - } - }); - } + @Override + public void start(Environment env) throws IOException { + startThread(new CommandRunnable() { + @Override + public void run() throws Exception { + parseCommandLine(); + stdout = toPrintWriter(out); + stderr = toPrintWriter(err); + try { + SshCommand.this.run(); + } finally { + stdout.flush(); + stderr.flush(); + } + } + }); + } - protected abstract void run() throws UnloggedFailure, Failure, Exception; + protected abstract void run() throws UnloggedFailure, Failure, Exception; } -- Gitblit v1.9.1