diff options
author | des <des@FreeBSD.org> | 2005-07-29 11:18:35 +0000 |
---|---|---|
committer | des <des@FreeBSD.org> | 2005-07-29 11:18:35 +0000 |
commit | 637e5e86f337e8ca035a449c62a8cbd0609d238c (patch) | |
tree | 8ac61672011f3590bad2be0a9172e6ce62eb7f95 /tools | |
parent | 81d2b39a725fa14cf4410fbe7bf0eb3b20d40643 (diff) | |
download | FreeBSD-src-637e5e86f337e8ca035a449c62a8cbd0609d238c.zip FreeBSD-src-637e5e86f337e8ca035a449c62a8cbd0609d238c.tar.gz |
Don't email reports that are empty or very short, as can happen if tbmaster
fails to exec the tinderbox script.
Diffstat (limited to 'tools')
-rw-r--r-- | tools/tools/tinderbox/tbmaster.pl | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tools/tools/tinderbox/tbmaster.pl b/tools/tools/tinderbox/tbmaster.pl index 39682e5..0ae6be0 100644 --- a/tools/tools/tinderbox/tbmaster.pl +++ b/tools/tools/tinderbox/tbmaster.pl @@ -206,6 +206,12 @@ sub report($$$$) { my $subject = shift; my $message = shift; + if (length($message) < 64) { + print(STDERR "[suspiciously short report, not sent by email]\n\n"); + print(STDERR $message); + return; + } + local *PIPE; if (open(PIPE, "|-", "/usr/sbin/sendmail", "-i", "-t", "-f$sender")) { print(PIPE "Sender: $sender\n"); |