Update RTC_LOGs in DtlsTransport to be able to distinguish errors.
There were two different codepaths that could trigger identical LOGs. b/136184428 Bug: None Change-Id: I3297c4e957177c3ffdd4c120cfa1b17d250f0a47 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/155582 Reviewed-by: Harald Alvestrand <hta@webrtc.org> Commit-Queue: Henrik Boström <hbos@webrtc.org> Cr-Commit-Position: refs/heads/master@{#29381}
This commit is contained in:

committed by
Commit Bot

parent
f83d0ef085
commit
ed8eadcb56
@ -645,13 +645,15 @@ void DtlsTransport::OnDtlsEvent(rtc::StreamInterface* dtls, int sig, int err) {
|
||||
SignalReadPacket(this, buf, read, rtc::TimeMicros(), 0);
|
||||
} else if (ret == rtc::SR_EOS) {
|
||||
// Remote peer shut down the association with no error.
|
||||
RTC_LOG(LS_INFO) << ToString() << ": DTLS transport closed";
|
||||
RTC_LOG(LS_INFO) << ToString() << ": DTLS transport closed by remote";
|
||||
set_writable(false);
|
||||
set_dtls_state(DTLS_TRANSPORT_CLOSED);
|
||||
} else if (ret == rtc::SR_ERROR) {
|
||||
// Remote peer shut down the association with an error.
|
||||
RTC_LOG(LS_INFO) << ToString()
|
||||
<< ": DTLS transport error, code=" << read_error;
|
||||
RTC_LOG(LS_INFO)
|
||||
<< ToString()
|
||||
<< ": Closed by remote with DTLS transport error, code="
|
||||
<< read_error;
|
||||
set_writable(false);
|
||||
set_dtls_state(DTLS_TRANSPORT_FAILED);
|
||||
}
|
||||
|
Reference in New Issue
Block a user