make sure our inetd fd > 2 - (code)
This commit is contained in:
parent
ddd30f921f
commit
0cc86455da
|
|
@ -349,8 +349,11 @@ int main (int argc, char ** argv)
|
||||||
|
|
||||||
/* inetd init */
|
/* inetd init */
|
||||||
if(inetd_mode) {
|
if(inetd_mode) {
|
||||||
|
/* make sure that out descriptor is not 0-2, we closing these */
|
||||||
|
for( opt=dup(0);opt>-1 && opt<=2; ) {
|
||||||
opt=dup(0);
|
opt=dup(0);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if(daemonize || inetd_mode)
|
if(daemonize || inetd_mode)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user