From d42413a4b4636422ba5ea66ba40e7d24fb64f9b1 Mon Sep 17 00:00:00 2001 From: Philipp Hancke Date: Thu, 4 Feb 2021 11:42:29 +0100 Subject: [PATCH] fix RTP_DUMP timestamps which was missing a setfill call, leading to invalid timestamps. BUG=webrtc:10675 Change-Id: Ib60f9f18b250aa89103e8de70b525df13c1042bd Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/205780 Reviewed-by: Harald Alvestrand Commit-Queue: Philipp Hancke Cr-Commit-Position: refs/heads/master@{#33183} --- pc/srtp_session.cc | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/pc/srtp_session.cc b/pc/srtp_session.cc index 0315c6a63e..78ec4e6ed9 100644 --- a/pc/srtp_session.cc +++ b/pc/srtp_session.cc @@ -477,9 +477,10 @@ void SrtpSession::DumpPacket(const void* buf, int len, bool outbound) { int64_t seconds = (time_of_day / 1000) % 60; int64_t millis = time_of_day % 1000; RTC_LOG(LS_VERBOSE) << "\n" << (outbound ? "O" : "I") << " " - << std::setw(2) << hours << ":" << std::setw(2) << minutes << ":" - << std::setw(2) << seconds << "." << std::setw(3) - << std::setfill('0') << millis << " " + << std::setfill('0') << std::setw(2) << hours << ":" + << std::setfill('0') << std::setw(2) << minutes << ":" + << std::setfill('0') << std::setw(2) << seconds << "." + << std::setfill('0') << std::setw(3) << millis << " " << "000000 " << rtc::hex_encode_with_delimiter((const char *)buf, len, ' ') << " # RTP_DUMP"; }