Commit 1c4670e
authored
is_valid_fd() now uses fstat() instead of dup() on macOS to return 0
on a pipe when the other side of the pipe is closed. fstat() fails
with EBADF in that case, whereas dup() succeed.
1 parent 5f161fd commit 1c4670e
1 file changed
Lines changed: 9 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1045 | 1045 | | |
1046 | 1046 | | |
1047 | 1047 | | |
| 1048 | + | |
| 1049 | + | |
| 1050 | + | |
| 1051 | + | |
| 1052 | + | |
| 1053 | + | |
| 1054 | + | |
| 1055 | + | |
1048 | 1056 | | |
1049 | 1057 | | |
1050 | 1058 | | |
| |||
1057 | 1065 | | |
1058 | 1066 | | |
1059 | 1067 | | |
| 1068 | + | |
1060 | 1069 | | |
1061 | 1070 | | |
1062 | 1071 | | |
| |||
0 commit comments