RFR(S) 8227868: jinfo and jstack can fail converting UTF8 output to strings
David Holmes
david.holmes at oracle.com
Mon Jul 22 04:13:30 UTC 2019
Hi Ralf,
On 19/07/2019 11:33 pm, Schmelter, Ralf wrote:
> Hi David,
>
> thanks for the review.
>
>> Not sure why you chose a 8K
>> buffer when existing codes uses 256 chars?
>
> I took it from the Reader.transferTo() method. But I've changed it to back to 256.
Okay.
>> There would ideally have been a regression test written for JDK-8222491
>> to demonstrate the conversion problem.
>
> I've added a test which shows the problem for jcmd. And I've modified the basic jstack test to test for the problem too. For jinfo testing would be much harder, since it either prints already sanitized output (system properties) or values which depend on the platform encoding (flags and command line).
The new test for Jcmd passes for me (linux x64 fastdebug) even without
the fix. But the modified jstack test fails.
The new test has the wrong id on the @bug line.
Thanks,
David
> Here is the update webrev: http://cr.openjdk.java.net/~rschmelter/webrevs/8227868/webrev.3/
>
> Best regards,
> Ralf
>
More information about the serviceability-dev
mailing list