Skip to content

Commit

Permalink
Fix regression on windows: Env var names are case insensitive
Browse files Browse the repository at this point in the history
  • Loading branch information
autoantwort committed Sep 27, 2024
1 parent 81b4999 commit 037d8cd
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/vcpkg/base/system.process.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -661,8 +661,9 @@ namespace vcpkg
{
auto pos = env_var.find('=');
auto key = env_var.substr(0, pos);
if (Util::Sets::contains(env_strings, key) ||
Util::any_of(env_prefix_string, [&](auto&& group) { return Strings::starts_with(key, group); }))
if (Util::Sets::contains(env_strings, key) || Util::any_of(env_prefix_string, [&](auto&& group) {
return Strings::case_insensitive_ascii_starts_with(key, group);
}))
{
auto value = pos == std::string::npos ? "" : env_var.substr(pos + 1);
env.add_entry(key, value);
Expand Down

0 comments on commit 037d8cd

Please sign in to comment.