RFR (S) 8222491: jcmd can fail converting UTF8 output to strings
Schmelter, Ralf
ralf.schmelter at sap.com
Tue Apr 16 12:47:04 UTC 2019
> I feel there must be a better way :) but the fix is fine as-is.
I share your feeling ;)
The best we could come up with was to use the transferTo(Writer) method on the InpuStreamReader.
But the PrintStream is unfortunately no Writer, although it is very close to being one. And wrapping the PrintStream in a OutputStreamWriter fails, since we cannot get the encoding used by the PrintStream (which is probably the default encoding, but I've not seen this specified).
More information about the serviceability-dev
mailing list