version 1.257, 2010/11/13 23:27:50 |
version 1.258, 2010/11/25 04:10:09 |
|
|
static void |
static void |
child_close_fds(void) |
child_close_fds(void) |
{ |
{ |
int i; |
|
|
|
if (packet_get_connection_in() == packet_get_connection_out()) |
if (packet_get_connection_in() == packet_get_connection_out()) |
close(packet_get_connection_in()); |
close(packet_get_connection_in()); |
else { |
else { |
|
|
* initgroups, because at least on Solaris 2.3 it leaves file |
* initgroups, because at least on Solaris 2.3 it leaves file |
* descriptors open. |
* descriptors open. |
*/ |
*/ |
for (i = 3; i < 64; i++) |
closefrom(STDERR_FILENO + 1); |
close(i); |
|
} |
} |
|
|
/* |
/* |