From 4baf798129da15dfdf5eed2d2ed0d9c64cd8cba3 Mon Sep 17 00:00:00 2001 From: Lukasz Mendakiewicz Date: Wed, 9 Aug 2017 14:35:36 -0700 Subject: [PATCH] Quote path in CreateProcess --- GoogleTestAdapter/Core/Helpers/ProcessExecutor.cs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/GoogleTestAdapter/Core/Helpers/ProcessExecutor.cs b/GoogleTestAdapter/Core/Helpers/ProcessExecutor.cs index ebdb6baff..953f58ff4 100644 --- a/GoogleTestAdapter/Core/Helpers/ProcessExecutor.cs +++ b/GoogleTestAdapter/Core/Helpers/ProcessExecutor.cs @@ -1,4 +1,6 @@ -using System; +// This file has been modified by Microsoft on 8/2017. + +using System; using System.Collections; using System.Collections.Generic; using System.Collections.Specialized; @@ -171,13 +173,12 @@ private static PROCESS_INFORMATION CreateProcess(string command, string paramete } }; - string commandLine = command; + string commandLine = $"\"{command}\""; if (!string.IsNullOrEmpty(parameters)) commandLine += $" {parameters}"; if (string.IsNullOrEmpty(workingDir)) workingDir = null; - PROCESS_INFORMATION processInfo; // ReSharper disable ArgumentsStyleNamedExpression // ReSharper disable ArgumentsStyleLiteral