Subject: Re: Warning message: Why do I care?
To: None <>
From: Steven M. Bellovin <>
List: current-users
Date: 08/01/2002 14:02:34
In message <>, writes:
>On Thu, Aug 01, 2002 at 12:34:07PM -0400, John Franklin wrote:
>> I disagree.  Too much software treats fd 0-2 as sacred.  I don't think
>> that open(2) should ever return a fd below 3.  I don't belive this would
>> break anything.
>how would you redirect output to a file then? usually this
>is implemented with something like
>  close(1);
>  fd = open("somefile", O_WRONLY);
You could use dup2().  But I suspect there's a lot of code around that 
does it your way.

		--Steve Bellovin, (me) ("Firewalls" book)