ibmi: Fix isatty EBADF handling and refactor#2753
Closed
kadler wants to merge 4 commits intolibuv:v1.xfrom
Closed
Conversation
In e14c56b, support was added to implement true isatty() support when running in the IBM i PASE environment, but it did not handle EBADF properly. This commit fixes the EBADF handling, but because the handling was a bit more complicated than previously, it was moved to a separate isatty function to keep the mainline code simpler. This also documents why we can't just use isatty on PASE a little more completely.
richardlau
approved these changes
Mar 25, 2020
Contributor
|
@kadler , seems compiler error happened? |
Member
Author
|
Is that in Node? I did not get an error when building just libuv. Well, we could work around that by renaming the function and making |
isatty was already declared as extern in the header files, since it is provided by libc, but we want ours static so it is not exported. This can cause errors when building, so instead rename the function and make isatty a macro wrapper around it.
dmabupt
suggested changes
Mar 25, 2020
Contributor
I can build libuv with the second commit. I use below configuration for libuv build & test -- I will test node.js build now, which may take some more time. |
Contributor
|
Tested with Node.js, the 55555 test passed! LGTM. |
Contributor
|
Need to revert the commit of PR nodejs/node#32338 once this PR landed into Node.js |
Member
richardlau
pushed a commit
to richardlau/libuv
that referenced
this pull request
Apr 6, 2020
In e14c56b, support was added to implement true isatty() support when running in the IBM i PASE environment, but it did not handle EBADF properly. This commit fixes the EBADF handling, but because the handling was a bit more complicated than previously, it was moved to a separate isatty function to keep the mainline code simpler. This also documents why we can't just use isatty on PASE a little more completely. PR-URL: libuv#2753 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
richardlau
pushed a commit
to richardlau/libuv
that referenced
this pull request
Apr 6, 2020
PR-URL: libuv#2753 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Member
|
Landed in 0ed9692...4878e82. |
richardlau
pushed a commit
to nodejs/node
that referenced
this pull request
Jun 1, 2020
Since the PR libuv/libuv#2753 has been landed, we need to revert the code change in PR #32338. PR-URL: #33629 Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
codebytere
pushed a commit
to nodejs/node
that referenced
this pull request
Jun 18, 2020
Since the PR libuv/libuv#2753 has been landed, we need to revert the code change in PR #32338. PR-URL: #33629 Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
codebytere
pushed a commit
to nodejs/node
that referenced
this pull request
Jun 30, 2020
Since the PR libuv/libuv#2753 has been landed, we need to revert the code change in PR #32338. PR-URL: #33629 Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
codebytere
pushed a commit
to nodejs/node
that referenced
this pull request
Jul 9, 2020
Since the PR libuv/libuv#2753 has been landed, we need to revert the code change in PR #32338. PR-URL: #33629 Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
liujinye-sys
pushed a commit
to open-vela/apps_system_libuv
that referenced
this pull request
Jul 23, 2025
In e14c56b, support was added to implement true isatty() support when running in the IBM i PASE environment, but it did not handle EBADF properly. This commit fixes the EBADF handling, but because the handling was a bit more complicated than previously, it was moved to a separate isatty function to keep the mainline code simpler. This also documents why we can't just use isatty on PASE a little more completely. PR-URL: libuv/libuv#2753 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
liujinye-sys
pushed a commit
to open-vela/apps_system_libuv
that referenced
this pull request
Jul 23, 2025
PR-URL: libuv/libuv#2753 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
liujinye-sys
pushed a commit
to open-vela/apps_system_libuv
that referenced
this pull request
Dec 16, 2025
In e14c56b, support was added to implement true isatty() support when running in the IBM i PASE environment, but it did not handle EBADF properly. This commit fixes the EBADF handling, but because the handling was a bit more complicated than previously, it was moved to a separate isatty function to keep the mainline code simpler. This also documents why we can't just use isatty on PASE a little more completely. PR-URL: libuv/libuv#2753 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
liujinye-sys
pushed a commit
to open-vela/apps_system_libuv
that referenced
this pull request
Dec 16, 2025
PR-URL: libuv/libuv#2753 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
In e14c56b, support was added to implement true isatty() support when
running in the IBM i PASE environment, but it did not handle EBADF
properly. This commit fixes the EBADF handling, but because the
handling was a bit more complicated than previously, it was moved to a
separate isatty function to keep the mainline code simpler.
This also documents why we can't just use isatty on PASE a little more
completely.