diff --git a/src/Build/BackEnd/Components/Communications/NodeLauncher.cs b/src/Build/BackEnd/Components/Communications/NodeLauncher.cs
index 96f58d52587..7e86c8f48a6 100644
--- a/src/Build/BackEnd/Components/Communications/NodeLauncher.cs
+++ b/src/Build/BackEnd/Components/Communications/NodeLauncher.cs
@@ -81,7 +81,12 @@ private Process StartInternal(string msbuildLocation, string commandLineArgs)
startInfo.hStdInput = BackendNativeMethods.InvalidHandle;
startInfo.hStdOutput = BackendNativeMethods.InvalidHandle;
startInfo.dwFlags = BackendNativeMethods.STARTFUSESTDHANDLES;
+
creationFlags |= BackendNativeMethods.CREATENOWINDOW;
+
+ // Avoid spawning a conhost.exe process, since this node won't do console output
+ // even though Windows thinks of us as a "console process"
+ creationFlags |= BackendNativeMethods.DETACHED_PROCESS;
}
}
else
diff --git a/src/Build/BackEnd/Node/NativeMethods.cs b/src/Build/BackEnd/Node/NativeMethods.cs
index c1540aae0c2..c570798b001 100644
--- a/src/Build/BackEnd/Node/NativeMethods.cs
+++ b/src/Build/BackEnd/Node/NativeMethods.cs
@@ -44,6 +44,11 @@ internal static class NativeMethods
///
internal const Int32 CREATE_NEW_CONSOLE = 0x00000010;
+ ///
+ /// For console processes, the new process does not inherit its parent's console (the default).
+ ///
+ internal const Int32 DETACHED_PROCESS = 0x00000008;
+
///
/// Create a new process
///