Skip to content

Commit b0f0a24

Browse files
committed
C#: Override env vars in DotNetCliInvoker if already set
1 parent f78c6e0 commit b0f0a24

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

csharp/extractor/Semmle.Extraction.CSharp.DependencyFetching/DotNetCliInvoker.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,9 @@ private ProcessStartInfo MakeDotnetStartInfo(string args, string? workingDirecto
4646
{
4747
logger.LogInfo($"Setting up Dependabot proxy at {this.proxy.Address}");
4848

49-
startInfo.EnvironmentVariables.Add("HTTP_PROXY", this.proxy.Address);
50-
startInfo.EnvironmentVariables.Add("HTTPS_PROXY", this.proxy.Address);
51-
startInfo.EnvironmentVariables.Add("SSL_CERT_FILE", this.proxy.CertificatePath);
49+
startInfo.EnvironmentVariables["HTTP_PROXY"] = this.proxy.Address;
50+
startInfo.EnvironmentVariables["HTTPS_PROXY"] = this.proxy.Address;
51+
startInfo.EnvironmentVariables["SSL_CERT_FILE"] = this.proxy.CertificatePath;
5252
}
5353

5454
return startInfo;

0 commit comments

Comments
 (0)