On Wed, 29 Apr 2026 16:04:08 GMT, Roger Riggs <[email protected]> wrote:

>> Test java/lang/ProcessBuilder/Basic.java fails with 'Exception: 
>> java.lang.Error: PATH search algorithm"
>> The tests in ProcessBuilder.Basic related to PATH search algorithm use the 
>> system binaries for /bin/true and /bin/false.
>> The tests proceed to copy the binaries to different directories on carefully 
>> constructed PATHs and verify the correct one is found.  
>> On some Linux OS's the binaries for /bin/true and /bin/false are the same 
>> binary. Distinguished only by arg[0] when executed.
>> On Ubuntu 25-10, copying the binary to `prog` and launching it, results in 
>> the exit status not being the expected value.
>> Musl and Apline systems have other limitations that are already reflected in 
>> special cases.
>> A solution proposed here is to provide separate binaries for the true and 
>> false functions so their invocation is more controlled.
>> 
>> Use native BasicTrue and BasicFalse executables in cases where /bin/true and 
>> /bin/false are not unique.
>> 
>> 
>> 
>> ---------
>> - [x] I confirm that I make this contribution in accordance with the 
>> [OpenJDK Interim AI Policy](https://openjdk.org/legal/ai).
>
> Roger Riggs has updated the pull request with a new target base due to a 
> merge or a rebase. The pull request now contains three commits:
> 
>  - Merge branch 'master' into 8379122-basic-path-search
>  - Merge branch 'master' into 8379122-basic-path-search
>  - 8379122: Test java/lang/ProcessBuilder/Basic.java fails with 'Exception: 
> java.lang.Error: PATH search algorithm"
>    Use native BasicTrue and BasicFalse executables in cases where /bin/true 
> and /bin/false
>    are not unique.

Hello Roger, this looks OK to me.

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

Marked as reviewed by jpai (Reviewer).

PR Review: https://git.openjdk.org/jdk/pull/30150#pullrequestreview-4205282799

Reply via email to