summaryrefslogtreecommitdiffstats
path: root/usr.sbin/sendmail/mailstats/mailstats.c
diff options
context:
space:
mode:
authorpeter <peter@FreeBSD.org>1997-06-27 15:17:19 +0000
committerpeter <peter@FreeBSD.org>1997-06-27 15:17:19 +0000
commitffc2d3d70315c587069f7268c77ccacce772a7e4 (patch)
tree8cbd2d8ef7f7d2877b971c8365f2641d3c6564ad /usr.sbin/sendmail/mailstats/mailstats.c
parent30e296b7618348906cd1a4d7dddfe581ded43a2a (diff)
downloadFreeBSD-src-ffc2d3d70315c587069f7268c77ccacce772a7e4.zip
FreeBSD-src-ffc2d3d70315c587069f7268c77ccacce772a7e4.tar.gz
Merge in sendmail-8.8.5 -> 8.8.6 changes to those files that have left the
vendor branch.
Diffstat (limited to 'usr.sbin/sendmail/mailstats/mailstats.c')
-rw-r--r--usr.sbin/sendmail/mailstats/mailstats.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/usr.sbin/sendmail/mailstats/mailstats.c b/usr.sbin/sendmail/mailstats/mailstats.c
index 3833da3..625b44c 100644
--- a/usr.sbin/sendmail/mailstats/mailstats.c
+++ b/usr.sbin/sendmail/mailstats/mailstats.c
@@ -40,7 +40,7 @@ static char copyright[] =
#endif /* not lint */
#ifndef lint
-static char sccsid[] = "@(#)mailstats.c 8.8 (Berkeley) 9/25/96";
+static char sccsid[] = "@(#)mailstats.c 8.10 (Berkeley) 5/30/97";
#endif /* not lint */
#define NOT_SENDMAIL
@@ -66,7 +66,7 @@ main(argc, argv)
bool mnames;
long frmsgs = 0, frbytes = 0, tomsgs = 0, tobytes = 0;
char mtable[MAXMAILERS][MNAMELEN+1];
- char sfilebuf[100];
+ char sfilebuf[MAXLINE];
char buf[MAXLINE];
extern char *ctime();
@@ -145,6 +145,13 @@ main(argc, argv)
}
/* this is the S or StatusFile option -- save it */
+ if (strlen(b) >= sizeof sfilebuf)
+ {
+ fprintf(stderr,
+ "StatusFile filename too long: %.30s...\n",
+ s);
+ exit(EX_CONFIG);
+ }
strcpy(sfilebuf, b);
b = strchr(sfilebuf, '#');
if (b == NULL)
OpenPOWER on IntegriCloud