RFR JDK-8232624: Java cannot start: NewStringPlatform missing
David Holmes
david.holmes at oracle.com
Mon Oct 21 01:19:12 UTC 2019
Hi Alexey,
On 21/10/2019 9:37 am, Alexey Ivanov wrote:
> Hi David,
>
> On 20/10/2019 23:59, David Holmes wrote:
>> Hi Alexey,
>>
>> On 21/10/2019 2:20 am, Alexey Ivanov wrote:
>>> Hello,
>>>
>>> Please review the following fix which it brings back
>>> NewStringPlatform alias for JNU_NewStringPlatform. Without it, 32 bit
>>> Windows build of Java does not work.
>>>
>>> bug: https://bugs.openjdk.java.net/browse/JDK-8232624
>>> webrev: http://cr.openjdk.java.net/~aivanov/8232624/webrev.00/
>>
>> Not sure this is the correct fix. The problem as I see it is that
>> NewStringPlatform was not declared as a JNICALL previously whereas the
>> JNU_NewStringPLatform is. That affects the linkage on 32-bit Windows
>> only.
>
> Yes, JNICALL affects 32-bit Windows only. And this is exactly why
> "JNU_NewStringPLatform" cannot be found by its name on 32-bit Windows;
> "NewStringPlatform" is not declared as JNICALL and it can be found by
> its undecorated name on 32-bit Windows and all the other platforms. I
> believe it's the reason why this alias exists.
So what would happen if we drop the JNICALL from JNU_NewStringPLatform?
> Another way to fix it is to lookup the undecorated name first and, if it
> fails, to lookup the decorated name, which makes the code harder to read.
>
> With this patch, I'm reverting the code to the state it was before.
Yes, but Claes didn't like the way it was before :) so I'm hoping we can
keep his cleanup whilst still allowing Windows to work correctly.
Thanks,
David
>>
>> David
More information about the core-libs-dev
mailing list