提交 d8c4aec0 编写于 作者: J Jim 提交者: GitHub

Merge pull request #1041 from RytoEX/fix-win10-revision-detection

libobs/util: Fix Windows 10 revision detection
......@@ -814,7 +814,7 @@ void get_win_ver(struct win_version_info *info)
get_dll_ver(L"kernel32", &ver);
got_version = true;
if (ver.major == 10 && ver.revis == 0) {
if (ver.major == 10) {
HKEY key;
DWORD size, win10_revision;
LSTATUS status;
......@@ -829,7 +829,8 @@ void get_win_ver(struct win_version_info *info)
status = RegQueryValueExW(key, L"UBR", NULL, NULL,
(LPBYTE)&win10_revision, &size);
if (status == ERROR_SUCCESS)
ver.revis = (int)win10_revision;
ver.revis = (int)win10_revision > ver.revis ?
(int)win10_revision : ver.revis;
RegCloseKey(key);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册