diff options
-rw-r--r-- | usr.sbin/inetd/inetd.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/usr.sbin/inetd/inetd.c b/usr.sbin/inetd/inetd.c index 486348c..b1582f0 100644 --- a/usr.sbin/inetd/inetd.c +++ b/usr.sbin/inetd/inetd.c @@ -604,6 +604,9 @@ main(argc, argv, envp) syslog(LOG_ERR, "%s/%s server failing (looping), service terminated", sep->se_service, sep->se_proto); + if (sep->se_accept && + sep->se_socktype == SOCK_STREAM) + close(ctrl); close_sep(sep); sigsetmask(0L); if (!timingout) { |