Mail Archives: djgpp-workers/2001/01/02/03:59:05
On Mon, 1 Jan 2001, Peter J. Farley III wrote:
> >I get the same results as you, but the output has file descriptor 7
> >rather than 5. (Please note that I did my tests on a copy of
> >unmodified sources from CVS, with Peter's patches.) I tested in the
> >same conditions as you, Peter.
>
> You ran them from inside bash. I ran under COMMAND.COM to get the *.ok
> files. When I run them under bash I get the same results as you, fd =
> 7.
If this matters (to let people know that the test passed), the test
program should forcibly close all handles above 2, before it embarks
on its main code.
> I think bash has more open file descriptors while running, so I
> think that explains the difference.
Yes, Bash takes 6 handles by default, IIRC, or at least uses handle 6
for output to the terminal.
Btw, does Bash on Unix marks those handles as close-on-exec? If so,
perhaps the DJGPP port should do that, too.
- Raw text -