Mail Archives: cygwin-developers/1998/11/13/20:20:13
---Corinna Vinschen <corinna DOT vinschen AT cityweb DOT de> wrote:
<snip>
> ...
> close(0);
> (void) dup(foo_fd);
> ...
>
It appears that the coder is assuming that dup will use the first
available file descriptor. This may not be true in all cases.
<snip>
> ...
> close(0);
> (void) dup2(foo_fd, 0);
> ...
For systems that support dup2 this would be more correct.
==
- \\||//
-------------------o0O0--Earnie--0O0o-------------------
-- earnie_boyd AT yahoo DOT com --
-- http://www.freeyellow.com/members5/gw32/index.html --
----------------------ooo0O--O0ooo----------------------
PS: Newbie's, you should visit my page.
_________________________________________________________
DO YOU YAHOO!?
Get your free @yahoo.com address at http://mail.yahoo.com
- Raw text -