JDK-8213773 : SA: '\0' terminate the interp_name string read in through pread for MacOS
Type:Bug
Component:hotspot
Sub-Component:svc-agent
Affected Version:10,11,12
Priority:P5
Status:Open
Resolution:Unresolved
OS:os_x
CPU:x86
Submitted:2018-11-13
Updated:2024-07-10
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.
The code improvement change of JDK-8140482 in ps_core.c of increasing the BUF_SIZE by 1 and adding the '\0' is needed for MacOS also. Keeping this as the placeholder for that.
Comments
The diff can be found here: https://github.com/openjdk/jdk/commit/3b8c97faaede#diff-8e7303740b64724263c3396ec61e02b07aa62073223dd3a1a10ac0fd15d5910bR814
Search for "case PT_INTERP:". The changes are pretty simple.