Skip to content
This repository was archived by the owner on Oct 25, 2024. It is now read-only.

Commit 4a33d67

Browse files
committed
Add recent Win10 versions for populating correct OsInfo (#96)
1 parent 67ed7e4 commit 4a33d67

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

rtc_base/win/windows_version.cc

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -207,8 +207,14 @@ Version MajorMinorBuildToVersion(int major, int minor, int build) {
207207
return VERSION_WIN10_RS4;
208208
} else if (build < 18362) {
209209
return VERSION_WIN10_RS5;
210-
} else {
210+
} else if (build < 18363) {
211+
return VERSION_WIN10_19H1;
212+
} else if (build < 19041) {
211213
return VERSION_WIN10_19H1;
214+
} else if (build < 19042) {
215+
return VERSION_WIN10_20H1;
216+
} else {
217+
return VERSION_WIN10_20H2;
212218
}
213219
} else if (major > 6) {
214220
RTC_NOTREACHED();

rtc_base/win/windows_version.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,9 @@ enum Version {
4545
VERSION_WIN10_RS4 = 12, // Redstone 4: Version 1803, Build 17134.
4646
VERSION_WIN10_RS5 = 13, // Redstone 5: Version 1809, Build 17763.
4747
VERSION_WIN10_19H1 = 14, // 19H1: Version 1903, Build 18362.
48+
VERSION_WIN10_19H2 = 15, // 19H2: Version 1909, Build 18363.
49+
VERSION_WIN10_20H1 = 16, // 20H1: Version 2004, Build 19041.
50+
VERSION_WIN10_20H2 = 17, // 20H2: Version 20H2, Build 19042.
4851
// On edit, update tools\metrics\histograms\enums.xml "WindowsVersion" and
4952
// "GpuBlacklistFeatureTestResultsWindows2".
5053
VERSION_WIN_LAST, // Indicates error condition.

0 commit comments

Comments
 (0)