JDK-8225225 : stringStream internal buffer should always be zero terminated
Type:Bug
Component:hotspot
Sub-Component:runtime
Affected Version:11,12,13
Priority:P4
Status:Resolved
Resolution:Fixed
Submitted:2019-06-04
Updated:2019-10-14
Resolved:2019-06-05
The Version table provides details related to the release that this issue/RFE will be addressed.
Unresolved : Release in which this issue/RFE will be addressed. Resolved: Release in which this issue/RFE has been resolved. Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.
It is currently not zero terminated after construction and after reset.
Comments
I see the patch applies cleanly now (after JDK-8220394). Restoring jdk11u-fix-request/jdk11u-fix-yes. Can be pushed after another cycle of testing.
03-09-2019
Fix Request:
Important to fix because: Fixes occurrences where stringStream internal buffers were not properly zero-terminated after stream was reset. May rarely lead to crashes or bad output.
Nature of fix: We now zero-terminate the internal buffer on reset() and after stream creation.
Low risk because: Simple fix. Fix comes with gtests regression tests.
Testing done: SAP nightlies (jck, jtreg, gtests etc)