From 4fdb944e26111010f3d9384c9eed74471cc56b5e Mon Sep 17 00:00:00 2001 From: Eric Allman Date: Sat, 10 Jun 1995 19:39:02 -0800 Subject: [PATCH] count children. Someday we might reject connections on this basis. SCCS-vsn: usr.sbin/sendmail/src/main.c 8.124 SCCS-vsn: usr.sbin/sendmail/src/daemon.c 8.98 SCCS-vsn: usr.sbin/sendmail/src/queue.c 8.87 --- usr/src/usr.sbin/sendmail/src/daemon.c | 4 ++-- usr/src/usr.sbin/sendmail/src/main.c | 3 ++- usr/src/usr.sbin/sendmail/src/queue.c | 6 ++++-- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/usr/src/usr.sbin/sendmail/src/daemon.c b/usr/src/usr.sbin/sendmail/src/daemon.c index abc93f935e..20b94c21f3 100644 --- a/usr/src/usr.sbin/sendmail/src/daemon.c +++ b/usr/src/usr.sbin/sendmail/src/daemon.c @@ -12,9 +12,9 @@ #ifndef lint #ifdef DAEMON -static char sccsid[] = "@(#)daemon.c 8.97 (Berkeley) %G% (with daemon mode)"; +static char sccsid[] = "@(#)daemon.c 8.98 (Berkeley) %G% (with daemon mode)"; #else -static char sccsid[] = "@(#)daemon.c 8.97 (Berkeley) %G% (without daemon mode)"; +static char sccsid[] = "@(#)daemon.c 8.98 (Berkeley) %G% (without daemon mode)"; #endif #endif /* not lint */ diff --git a/usr/src/usr.sbin/sendmail/src/main.c b/usr/src/usr.sbin/sendmail/src/main.c index f142636e4f..8d08021b21 100644 --- a/usr/src/usr.sbin/sendmail/src/main.c +++ b/usr/src/usr.sbin/sendmail/src/main.c @@ -13,7 +13,7 @@ static char copyright[] = #endif /* not lint */ #ifndef lint -static char sccsid[] = "@(#)main.c 8.123 (Berkeley) %G%"; +static char sccsid[] = "@(#)main.c 8.124 (Berkeley) %G%"; #endif /* not lint */ #define _DEFINE @@ -1597,6 +1597,7 @@ dumpstate(when) if (!wordinclass(j, 'w')) syslog(LOG_DEBUG, "*** $j not in $=w ***"); } + syslog(LOG_DEBUG, "CurChildren = %d", CurChildren); syslog(LOG_DEBUG, "--- open file descriptors: ---"); printopenfds(TRUE); syslog(LOG_DEBUG, "--- connection cache: ---"); diff --git a/usr/src/usr.sbin/sendmail/src/queue.c b/usr/src/usr.sbin/sendmail/src/queue.c index d448cb813a..47fed6c1a6 100644 --- a/usr/src/usr.sbin/sendmail/src/queue.c +++ b/usr/src/usr.sbin/sendmail/src/queue.c @@ -10,9 +10,9 @@ #ifndef lint #ifdef QUEUE -static char sccsid[] = "@(#)queue.c 8.86 (Berkeley) %G% (with queueing)"; +static char sccsid[] = "@(#)queue.c 8.87 (Berkeley) %G% (with queueing)"; #else -static char sccsid[] = "@(#)queue.c 8.86 (Berkeley) %G% (without queueing)"; +static char sccsid[] = "@(#)queue.c 8.87 (Berkeley) %G% (without queueing)"; #endif #endif /* not lint */ @@ -510,6 +510,8 @@ runqueue(forkflag) /* parent -- pick up intermediate zombie */ #ifndef SIGCHLD (void) waitfor(pid); +#else + CurChildren++; #endif /* SIGCHLD */ if (QueueIntvl != 0) (void) setevent(QueueIntvl, runqueue, TRUE); -- 2.20.1