On Mon, 10 Feb 2003, Alberto Gonzalez Iniesta wrote:
>
> Hi,
>
> Again, I'm no C hacker, but I think this should be better:
>
> for(x = 3; x < 100; x++)
>
> Since the first 3 fds (stdin, stdout and stderr) should be kept open.
>
Wasn't sure if stdin, stdout and stderr needed to be left open or not
On Mon, 2003-02-10 at 02:01, Aaron Sethman wrote:
> Here is a simple little replacement for system() that does close file
> descriptors. The main issue with it is though, it ends up picking an
> arbitrary number of fds to close. I picked closing 0 to 99.
You can use getdtablesize() to determine
On Sun, Feb 09, 2003 at 08:01:12PM -0500, Aaron Sethman wrote:
>
> Here is a simple little replacement for system() that does close file
> descriptors. The main issue with it is though, it ends up picking an
> arbitrary number of fds to close. I picked closing 0 to 99.
>
> Aaron
>
>
> int s_s
Aaron Sethman wrote:
Here is a simple little replacement for system() that does close file
descriptors. The main issue with it is though, it ends up picking an
arbitrary number of fds to close. I picked closing 0 to 99.
I don't think this is necessary. Every file descriptor has a "close on