summaryrefslogtreecommitdiff
path: root/usr.sbin/smtpd
diff options
context:
space:
mode:
authorJacek Masiulaniec <jacekm@cvs.openbsd.org>2009-09-16 20:22:19 +0000
committerJacek Masiulaniec <jacekm@cvs.openbsd.org>2009-09-16 20:22:19 +0000
commitde27ee6418c1016cdc0994fcc5648097526f264b (patch)
tree8b8042ca09505cd15f287bba10fed4215196e217 /usr.sbin/smtpd
parent5900f66163537e8fcdd7bc2fc894150c61a1d899 (diff)
Do not print "could not load cert" warning at startup if certificate is not
required. Requested by jmc@, gilles@ ok.
Diffstat (limited to 'usr.sbin/smtpd')
-rw-r--r--usr.sbin/smtpd/parse.y17
1 files changed, 6 insertions, 11 deletions
diff --git a/usr.sbin/smtpd/parse.y b/usr.sbin/smtpd/parse.y
index c7b8313a27e..f60d4719bd4 100644
--- a/usr.sbin/smtpd/parse.y
+++ b/usr.sbin/smtpd/parse.y
@@ -1,4 +1,4 @@
-/* $OpenBSD: parse.y,v 1.38 2009/06/05 23:04:51 jacekm Exp $ */
+/* $OpenBSD: parse.y,v 1.39 2009/09/16 20:22:18 jacekm Exp $ */
/*
* Copyright (c) 2008 Gilles Chehade <gilles@openbsd.org>
@@ -266,16 +266,11 @@ main : QUEUE INTERVAL interval {
if ($7)
flags |= F_AUTH;
- if (ssl_load_certfile(conf, cert, F_SCERT) < 0) {
- log_warnx("warning: could not load cert: %s, "
- "no SSL/TLS/AUTH support", cert);
- if ($5) {
- yyerror("cannot load certificate: %s",
- cert);
- free($6);
- free($3);
- YYERROR;
- }
+ if ($5 && ssl_load_certfile(conf, cert, F_SCERT) < 0) {
+ yyerror("cannot load certificate: %s", cert);
+ free($6);
+ free($3);
+ YYERROR;
}
if (! interface($3, cert, conf->sc_listeners,