-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
wsl: skip distributions that indicate they are "Modern" #18183
Conversation
@@ -188,6 +189,12 @@ static bool getWslNames(const wil::unique_hkey& wslRootKey, | |||
continue; | |||
} | |||
|
|||
const auto modernValue{ wil::reg::try_get_value<uint32_t>(distroKey.get(), RegKeyModern) }; | |||
if (modernValue == 1u) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it's an optional
- nullopt
is !=
1 :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd prefer if this was .value_or(0) != 0
because that would more accurately represent "truthy".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So... what does this do? :D
(cherry picked from commit 00ff803) Service-Card-Id: PVTI_lADOAF3p4s4AmhmszgUu4sc Service-Version: 1.21
(cherry picked from commit 00ff803) Service-Card-Id: PVTI_lADOAF3p4s4AmhmQzgUu4sg Service-Version: 1.22
No description provided.