RFR: 8331708: jdk/internal/jline/RedirectedStdOut.java times-out on macosx-aarch64
Adam Sotona
asotona at openjdk.org
Mon May 6 08:38:52 UTC 2024
On Mon, 6 May 2024 08:28:50 GMT, Jan Lahoda <jlahoda at openjdk.org> wrote:
> When integrating:
> https://github.com/openjdk/jdk/pull/18996
>
> I've forgot to push one last commit which was stabilizing the test of Mac OS/X. I am sorry for that.
>
> The test will create a pseudo terminal, and change the current process stdin/stdout to write into the pty. But, there's nothing reading from the pty on the other side. This mostly works, OK, but the `ProcessTools` will write a debug log into `System.out` (which will write to stdout, which is the pty), and that blocks on Mac OS/X, presumably because there's nothing reading from the pty.
>
> This patch changes the `System.out` for the main process to a scratch value, so no write to stdout/FD 1 is done, and no blocking should happen. (The process' stdout/FD 1 should remain attached to the pty.)
It looks good, the test works on macosx-aarch64.
-------------
Marked as reviewed by asotona (Reviewer).
PR Review: https://git.openjdk.org/jdk/pull/19097#pullrequestreview-2040267279
More information about the core-libs-dev
mailing list