Re: /bin/sh fd 12

2021-09-14 Thread Jan Schaumann
Robert Elz wrote: > And it was committed. Nice - thanks for fixing this so promptly! -Jan

Re: /bin/sh fd 12

2021-09-14 Thread Robert Elz
Date:Tue, 14 Sep 2021 21:26:43 +0700 From:Robert Elz Message-ID: <14651.1631629...@jinx.noi.kre.to> | the fix is almost done. And it was committed. But then it was just almost almost done ... now it should really be almost done. What I committed last night is

Re: /bin/sh fd 12

2021-09-14 Thread Robert Elz
Date:Tue, 14 Sep 2021 09:12:17 -0400 From:Jan Schaumann Message-ID: <20210914131217.gk6...@netmeister.org> | Do you want me to send-pr the redirection to fds | 12/13? You can if you want, but the fix is almost done. (My test build is just completing now, then

Re: /bin/sh fd 12

2021-09-14 Thread Jan Schaumann
Robert Elz wrote: > When you redirect standard output of a built-in command, the > existing standard output needs to be moved somewhere else (saved) > before the new one can be opened (dup'd in this case). 13 is > the next available fd I see, thanks. It looks like the selection of fd 12

Re: /bin/sh fd 12

2021-09-14 Thread Robert Elz
Date:Tue, 14 Sep 2021 06:14:31 - (UTC) From:mlel...@serpens.de (Michael van Elst) Message-ID: | /bin/sh uses /dev/tty for job control which is enabled automatically | when running as interactive shell. But there is a -m option where | you can enable/disable

Re: /bin/sh fd 12

2021-09-14 Thread Robert Elz
Date:Mon, 13 Sep 2021 23:32:39 -0400 From:Jan Schaumann Message-ID: <20210914033238.gj6...@netmeister.org> | 0, 1, and 2 are obvious, but fd 12 did not seem | obvious to me. | | Descriptor 12 being open to the current terminal means | I can do this: | |

Re: /bin/sh fd 12

2021-09-14 Thread Michael van Elst
jscha...@netmeister.org (Jan Schaumann) writes: >Hello, >$ ls -li /proc/$$/fd/ >total 0 > 5 crw--w 1 jschauma tty5, 1 Sep 14 02:47 0 > 5 crw--w 1 jschauma tty5, 1 Sep 14 02:47 1 >1090579 crw-rw-rw- 1 root wheel 1, 0 Sep 14 02:19 12 > 5 crw--w 1

/bin/sh fd 12

2021-09-13 Thread Jan Schaumann
Hello, I was looking at open file descriptors of /bin/sh under procfs: $ ls -li /proc/$$/fd/ total 0 5 crw--w 1 jschauma tty5, 1 Sep 14 02:47 0 5 crw--w 1 jschauma tty5, 1 Sep 14 02:47 1 1090579 crw-rw-rw- 1 root wheel 1, 0 Sep 14 02:19 12 5