RFR: 8304498: JShell does not switch to raw mode when there is no /bin/test [v2]

Vicente Romero vromero at openjdk.org
Mon Mar 27 15:38:57 UTC 2023


On Wed, 22 Mar 2023 18:38:08 GMT, Jan Lahoda <jlahoda at openjdk.org> wrote:

>> If JShell is run on a system that does not have `/bin/test` (which is, apparently, possible for some systems, which only have `/usr/bin/test`), it won't switch the terminal into the raw mode, and the input will not work properly.
>> 
>> The proposed fix herein is to detect whether `test` existing in `/usr/bin/test`, and if yes, use that location. Use the existing `/bin/test` otherwise.
>
> Jan Lahoda has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Checking the executable flags instead of running the program, as suggested.

looks sensible

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

Marked as reviewed by vromero (Reviewer).

PR Review: https://git.openjdk.org/jdk/pull/13100#pullrequestreview-1359340541


More information about the core-libs-dev mailing list