Browse Source

[findBugs] Use UTF-8 when writing to the error stream in jgit pgm

Change-Id: Ic2555ea932dbbd1a3a6868e731f247b9754d7f09
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
stable-4.8
Matthias Sohn 8 years ago
parent
commit
475dcc2985
  1. 5
      org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Main.java

5
org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Main.java

@ -44,8 +44,11 @@
package org.eclipse.jgit.pgm;
import static java.nio.charset.StandardCharsets.UTF_8;
import java.io.File;
import java.io.IOException;
import java.io.OutputStreamWriter;
import java.io.PrintWriter;
import java.lang.reflect.InvocationTargetException;
import java.net.MalformedURLException;
@ -192,7 +195,7 @@ public class Main {
}
PrintWriter createErrorWriter() {
return new PrintWriter(System.err);
return new PrintWriter(new OutputStreamWriter(System.err, UTF_8));
}
private void execute(final String[] argv) throws Exception {

Loading…
Cancel
Save