Skip to content

Commit

Permalink
Item12180: Align log messages.
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.foswiki.org/trunk@16272 0b4bb1d4-4e5a-0410-9cc4-b2b747904278
  • Loading branch information
TimotheLitt authored and TimotheLitt committed Dec 24, 2012
1 parent 761b14c commit 8775e50
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions core/lib/Foswiki/Configure/Checkers/EnableEmail.pm
Original file line number Diff line number Diff line change
Expand Up @@ -1102,21 +1102,23 @@ sub starttls {

unless ( defined $smtp->supports('STARTTLS') ) {
$smtp->quit;
$$e .= $this->NOTE( $tlog, "STARTTLS is not supported by $host" );
$$e .= $this->NOTE( $tlog,
"${pad}STARTTLS is not supported by $host</pre>" );
return 0;
}
unless ( $smtp->command('STARTTLS')->response() == 2 ) {
$smtp->quit;
$$e .= $this->NOTE( $tlog . "STARTTLS command failed</pre>" );
$$e .= $this->NOTE( $tlog . "${pad}STARTTLS command failed</pre>" );
return 0;
}

my $mailobj = ref $smtp;

unless ( IO::Socket::SSL->start_SSL( $smtp, @sockopts ) ) {
$tlog .= $pad . IO::Socket::SSL::errstr() . "\n";
$$e .= $this->NOTE( $tlog . "Upgrade to TLS failed</pre>" );
$$e .= $this->NOTE( $tlog . "${pad}Upgrade to TLS failed</pre>" );

# Note: The server may still be trying to talk SSL; we can't quit.
$smtp->close;
return 0;
}
Expand All @@ -1130,7 +1132,7 @@ sub starttls {
. fmtcertnames( $smtp->dump_peer_certificate ) );

unless ( $smtp->hello($hello) ) {
$$e .= $this->NOTE( $tlog . "Hello failed</pre>" );
$$e .= $this->NOTE( $tlog . "${pad}Hello failed</pre>" );
$smtp->quit();
return 0;
}
Expand Down

0 comments on commit 8775e50

Please sign in to comment.