diff --git a/java/compiler/impl/src/com/intellij/compiler/CompileServerManager.java b/java/compiler/impl/src/com/intellij/compiler/CompileServerManager.java index d34ce9d92a7b..9dd764011b14 100644 --- a/java/compiler/impl/src/com/intellij/compiler/CompileServerManager.java +++ b/java/compiler/impl/src/com/intellij/compiler/CompileServerManager.java @@ -283,7 +283,7 @@ public class CompileServerManager implements ApplicationComponent{ // re-translate server's output to idea.log final String text = event.getText(); if (!StringUtil.isEmpty(text)) { - LOG.info("COMPILE_SERVER [" +outputType.toString() +"]: "+ text); + LOG.info("COMPILE_SERVER [" +outputType.toString() +"]: "+ text.trim()); } } }); diff --git a/jps/jps-builders/src/org/jetbrains/jps/javac/JavacServerBootstrap.java b/jps/jps-builders/src/org/jetbrains/jps/javac/JavacServerBootstrap.java index cdd778e32ff1..aece320b89a0 100644 --- a/jps/jps-builders/src/org/jetbrains/jps/javac/JavacServerBootstrap.java +++ b/jps/jps-builders/src/org/jetbrains/jps/javac/JavacServerBootstrap.java @@ -95,8 +95,13 @@ public class JavacServerBootstrap { processHandler.addProcessListener(new ProcessAdapter() { public void onTextAvailable(ProcessEvent event, Key outputType) { final String text = event.getText(); - if (text != null && text.length() > 0) { - System.out.print("JAVAC_SERVER [" + outputType.toString() + "]: " + text); + if (!StringUtil.isEmpty(text)) { + if (outputType == ProcessOutputTypes.STDOUT) { + System.out.print("JAVAC_SERVER: " + text); + } + else if (outputType == ProcessOutputTypes.STDERR){ + System.err.print("JAVAC_SERVER: " + text); + } } } });