Revert "Fix output period in RtcEventLogImpl"

This reverts commit a4dcb749fbbc83a874d4e2c65de5a98465d3e200.

Reason for revert: Speculative revert. Tsan failure has been consistently generated after this CL.

Original change's description:
> Fix output period in RtcEventLogImpl
> 
> RtcEventLogImpl::StartLogging() was ignoring one of its parameters.
> This CL fixes the issue.
> 
> Bug: webrtc:10082
> Change-Id: Ie1790c1a7299748dabe99909d967384ad9895635
> Reviewed-on: https://webrtc-review.googlesource.com/c/112586
> Reviewed-by: Björn Terelius <terelius@webrtc.org>
> Commit-Queue: Elad Alon <eladalon@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#25858}

TBR=eladalon@webrtc.org,terelius@webrtc.org

Change-Id: I6b79c207d537ab6ca44bb418958854acebc886ac
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:10082
Reviewed-on: https://webrtc-review.googlesource.com/c/112740
Reviewed-by: Qingsi Wang <qingsi@webrtc.org>
Commit-Queue: Qingsi Wang <qingsi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25864}
This commit is contained in:
Qingsi Wang 2018-12-01 00:47:56 +00:00 committed by Commit Bot
parent 7c6fbf2c9a
commit 2bb96682a2

View File

@ -179,11 +179,10 @@ bool RtcEventLogImpl::StartLogging(std::unique_ptr<RtcEventLogOutput> output,
<< "(" << timestamp_us << ", " << utc_time_us << ")."; << "(" << timestamp_us << ", " << utc_time_us << ").";
// Binding to |this| is safe because |this| outlives the |task_queue_|. // Binding to |this| is safe because |this| outlives the |task_queue_|.
auto start = [this, output_period_ms, timestamp_us, auto start = [this, timestamp_us,
utc_time_us](std::unique_ptr<RtcEventLogOutput> output) { utc_time_us](std::unique_ptr<RtcEventLogOutput> output) {
RTC_DCHECK_RUN_ON(task_queue_.get()); RTC_DCHECK_RUN_ON(task_queue_.get());
RTC_DCHECK(output->IsActive()); RTC_DCHECK(output->IsActive());
output_period_ms_ = output_period_ms;
event_output_ = std::move(output); event_output_ = std::move(output);
num_config_events_written_ = 0; num_config_events_written_ = 0;
WriteToOutput(event_encoder_->EncodeLogStart(timestamp_us, utc_time_us)); WriteToOutput(event_encoder_->EncodeLogStart(timestamp_us, utc_time_us));