RFR: 8364312: debug agent should set FD_CLOEXEC flag rather than explicitly closing every open file [v4]

Guanqiang Han ghan at openjdk.org
Thu Aug 7 02:14:22 UTC 2025


On Wed, 6 Aug 2025 15:37:07 GMT, Kevin Walls <kevinw at openjdk.org> wrote:

>> Guanqiang Han has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains six additional commits since the last revision:
>> 
>>  - update some comments
>>  - Merge remote-tracking branch 'upstream/master' into 8364312
>>  - a small fix
>>  - Merge remote-tracking branch 'upstream/master' into 8364312
>>  - Update exec_md.c
>>    
>>    correct an compilation error
>>  - 8364312: debug agent should set FD_CLOEXEC flag rather than explicitly closing every open file
>>    
>>    Create a new function that marks all file descriptors found in /proc/self/fd with the FD_CLOEXEC flag to ensure they are automatically closed upon execution of a new program via exec().
>
> If you reproduce a timeout in your local run and it does relate to this change, please update here.
> But I ran the above test list locally on linux-x64 and saw no issues.  Looks like we have all done some testing.

@kevinjwalls Thank you for the sponsorship !

I re-ran the tests several times today on my local Linux x64 machine and didn't observe any timeouts. It's likely that the earlier timeout I encountered was due to limited resources on my virtual machine. Everything looks good now.

-------------

PR Comment: https://git.openjdk.org/jdk/pull/26568#issuecomment-3162182935


More information about the serviceability-dev mailing list