SCCS-vsn: usr.sbin/sendmail/src/collect.c 1.4
# include <stdio.h>
# include <ctype.h>
# include <stdio.h>
# include <ctype.h>
# include "dlvrmail.h"
static char SccsId[] = "@(#)collect.c 1.4 %G%";
# include "dlvrmail.h"
static char SccsId[] = "@(#)collect.c 1.4 %G%";
register bool inheader;
bool firstline;
char c;
register bool inheader;
bool firstline;
char c;
/*
** Create the temp file name and create the file.
/*
** Create the temp file name and create the file.
firstline = FALSE;
if (ferror(tf))
{
firstline = FALSE;
if (ferror(tf))
{
- syserr("Cannot write %s", InFileName);
- clearerr(tf);
- break;
+ if (errno == ENOSPC)
+ {
+ freopen(InFileName, "w", tf);
+ fputs("\nMAIL DELETED BECAUSE OF LACK OF DISK SPACE\n\n", tf);
+ syserr("Out of disk space for temp file");
+ }
+ else
+ syserr("Cannot write %s", InFileName);
+ freopen("/dev/null", "w", tf);