RFR: 8253702: BigSur java/lang/System/OsVersionTest.java: 10.16 != 11.0 [v2]

Kevin Rushforth kcr at openjdk.java.net
Thu Feb 11 19:15:43 UTC 2021


On Thu, 11 Feb 2021 18:53:08 GMT, Kevin Rushforth <kcr at openjdk.org> wrote:

>> Roger Riggs has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Correct double-negative in 'other than 10.16'
>
> src/java.base/macosx/native/libjava/java_props_macosx.c line 262:
> 
>> 260:             // Copy out the char*
>> 261:             osVersionCStr = strdup([nsVerStr UTF8String]);
>> 262:         } else if (getenv("SYSTEM_VERSION_COMPAT") == NULL) {
> 
> If version is 10.16 and `SYSTEM_VERSION_COMPAT` is set, you will fall through to the pre-10.9 Mac OS code fallback. Just checking to see if that's what you intended.

FWIW, it seems to work OK using the legacy fallback path (reports 10.16 if I set `SYSTEM_VERSION_COMPAT=1`).

-------------

PR: https://git.openjdk.java.net/jdk/pull/2530


More information about the core-libs-dev mailing list