Skip to content

Commit d5b5497

Browse files
Update link to OSVersion net5.0 breaking change (dotnet#8591)
1 parent 0aae9b7 commit d5b5497

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

xml/System/Environment.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1707,7 +1707,7 @@ The following example creates environment variables for the <xref:System.Environ
17071707
17081708
## Remarks
17091709
1710-
In .NET versions prior to .NET 5, <xref:System.Environment.OSVersion?displayProperty=nameWithType> returns an OS version that may be incorrect when an application runs under Windows compatibility mode. For more information, see [GetVersionExA function remarks](/windows/win32/api/sysinfoapi/nf-sysinfoapi-getversionexa#remarks). In .NET 5 and later versions, <xref:System.Environment.OSVersion?displayProperty=nameWithType> always returns the actual OS version. For more information, see [Environment.OSVersion returns the correct operating system version](/dotnet/core/compatibility/corefx#environmentosversion-returns-the-correct-operating-system-version).
1710+
In .NET versions prior to .NET 5, <xref:System.Environment.OSVersion?displayProperty=nameWithType> returns an OS version that may be incorrect when an application runs under Windows compatibility mode. For more information, see [GetVersionExA function remarks](/windows/win32/api/sysinfoapi/nf-sysinfoapi-getversionexa#remarks). In .NET 5 and later versions, <xref:System.Environment.OSVersion?displayProperty=nameWithType> always returns the actual OS version. For more information, see [Environment.OSVersion returns the correct operating system version](/dotnet/core/compatibility/core-libraries/5.0/environment-osversion-returns-correct-version).
17111711
17121712
To identify the operating system platform, for example, Linux or Windows, you can use the <xref:System.Runtime.InteropServices.RuntimeInformation.IsOSPlatform%2A?displayProperty=nameWithType> method.
17131713

0 commit comments

Comments
 (0)