Prevent queueing workitems in debuggee compilation on prebuild path (#2480)
authorJuan Hoyos <juan.hoyos@microsoft.com>
Thu, 5 Aug 2021 18:47:28 +0000 (11:47 -0700)
committerGitHub <noreply@github.com>
Thu, 5 Aug 2021 18:47:28 +0000 (11:47 -0700)
src/Microsoft.Diagnostics.TestHelpers/PrebuiltDebuggeeCompiler.cs
src/Microsoft.Diagnostics.TestHelpers/SdkPrebuiltDebuggeeCompiler.cs

index 0c6cb51f0725cb562fb0187abc65a324c8381bd5..c7544da462143f5f18238f951388f5bef0228e01 100644 (file)
@@ -32,7 +32,7 @@ namespace Microsoft.Diagnostics.TestHelpers
 
         public Task<DebuggeeConfiguration> Execute(ITestOutputHelper output)
         {
-            return Task.Factory.StartNew<DebuggeeConfiguration>(() => new DebuggeeConfiguration(_sourcePath, _binaryPath, _binaryExePath));
+            return Task.FromResult<DebuggeeConfiguration>(new DebuggeeConfiguration(_sourcePath, _binaryPath, _binaryExePath));
         }
     }
 }
\ No newline at end of file
index 53fd4187fc5990bba849027417c758d5fbf9498b..67e374a0fdd04d46f228fd482417de5dca59c612 100644 (file)
@@ -31,7 +31,7 @@ namespace Microsoft.Diagnostics.TestHelpers
 
         public Task<DebuggeeConfiguration> Execute(ITestOutputHelper output)
         {
-            return Task.Factory.StartNew<DebuggeeConfiguration>(() => new DebuggeeConfiguration(_sourcePath, _binaryPath, _binaryExePath));
+            return Task.FromResult<DebuggeeConfiguration>(new DebuggeeConfiguration(_sourcePath, _binaryPath, _binaryExePath));
         }
     }
 }
\ No newline at end of file