Skip to content

Commit

Permalink
fix empty connection debug logs (#14666)
Browse files Browse the repository at this point in the history
Fixes #14661

Signed-off-by: Rama Chavali <rama.rao@salesforce.com>
  • Loading branch information
ramaraochavali authored Jan 12, 2021
1 parent dcf575a commit e9ffbc5
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion source/extensions/transport_sockets/tls/ssl_socket.cc
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,9 @@ void SslSocket::drainErrorQueue() {
ERR_func_error_string(err), ":",
ERR_reason_error_string(err)));
}
ENVOY_CONN_LOG(debug, "{}", callbacks_->connection(), failure_reason_);
if (!failure_reason_.empty()) {
ENVOY_CONN_LOG(debug, "{}", callbacks_->connection(), failure_reason_);
}
if (saw_error && !saw_counted_error) {
ctx_->stats().connection_error_.inc();
}
Expand Down

0 comments on commit e9ffbc5

Please sign in to comment.