RFR: 8360401: [AIX] java/lang/ProcessBuilder/FDLeakTest/FDLeakTest.java fails since JDK-8210549
Matthias Baesken
mbaesken at openjdk.org
Mon Sep 22 13:33:52 UTC 2025
On Mon, 22 Sep 2025 13:10:30 GMT, Joachim Kern <jkern at openjdk.org> wrote:
>> src/java.base/unix/native/libjava/childproc.c line 73:
>>
>>> 71: /* The /proc file System in AIX does not contain open system files
>>> 72: * like /dev/random. Therefore we use a different approach and do
>>> 73: * not need isAsciiDigit() or FD_DIR */
>>
>> Leave isAsciiDigit in; optionally replace it with https://pubs.opengroup.org/onlinepubs/009696699/functions/isdigit.html .
>>
>> Reduction of ifdefs is more important than avoiding an unnecessary function.
>
> Sorry the compiler forced this:
> /data/d042520/FDLeak/jdk/src/java.base/unix/native/libjava/childproc.c:75:1: error: unused function 'isAsciiDigit' [-Werror,-Wunused-function]
> 75 | isAsciiDigit(char c)
> | ^~~~~~~~~~~~
> 1 error generated.
The previous
`#if defined(_AIX)`
is just moved up and is now a
`#if !defined(_AIX)`
so it is as good or bad as before when looking at platform ifdefs ; not ideal but considering the warning mentioned above it is probably okay.
> Hi Thomas, fcntl(4, F_CLOSEM, 0); closes all open descriptors >=4. Its a special AIX feature linux does not have i guess.
Might be worth pointing out in the comment above.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/27291#discussion_r2368411247
PR Review Comment: https://git.openjdk.org/jdk/pull/27291#discussion_r2368419942
More information about the core-libs-dev
mailing list