Chromium Code Reviews| Index: webrtc/voice_engine/channel_manager.cc |
| diff --git a/webrtc/voice_engine/channel_manager.cc b/webrtc/voice_engine/channel_manager.cc |
| index 76664d4b12ccd9becadd39f81363fc6b72a8e38c..8301341337f15aae2bdb88a056ece7a7f596d5d6 100644 |
| --- a/webrtc/voice_engine/channel_manager.cc |
| +++ b/webrtc/voice_engine/channel_manager.cc |
| @@ -45,23 +45,31 @@ ChannelOwner& ChannelOwner::operator=(const ChannelOwner& other) { |
| ChannelOwner::ChannelRef::ChannelRef(class Channel* channel) |
| : channel(channel), ref_count(1) {} |
| -ChannelManager::ChannelManager(uint32_t instance_id, const Config& config) |
| +ChannelManager::ChannelManager(uint32_t instance_id, |
| + const Config& config, |
| + RtcEventLog* const event_log) |
| : instance_id_(instance_id), |
| last_channel_id_(-1), |
| lock_(CriticalSectionWrapper::CreateCriticalSection()), |
| - config_(config) {} |
| + config_(config), |
| + event_log_(event_log) { |
| +} |
| ChannelOwner ChannelManager::CreateChannel() { |
| - return CreateChannelInternal(config_); |
| + return CreateChannelInternal(config_, event_log_); |
| } |
| -ChannelOwner ChannelManager::CreateChannel(const Config& external_config) { |
| - return CreateChannelInternal(external_config); |
| +ChannelOwner ChannelManager::CreateChannel(const Config& external_config, |
| + RtcEventLog* const event_log) { |
|
Henrik Grunell WebRTC
2015/08/12 12:43:45
Will we ever use another event log than the one gi
ivoc
2015/08/12 13:16:41
That is certainly an option, do you think it would
Henrik Grunell WebRTC
2015/08/12 15:29:53
I think the raw pointer should be avoided if not n
ivoc
2015/08/13 07:49:23
I'm not sure what you mean exactly by avoiding the
Henrik Grunell WebRTC
2015/08/13 08:13:55
I mean having a scoped_ptr only at one place only.
ivoc
2015/08/13 13:33:43
Ah okay, that is a good point. I moved the RtcEven
|
| + return CreateChannelInternal(external_config, event_log); |
| } |
| -ChannelOwner ChannelManager::CreateChannelInternal(const Config& config) { |
| +ChannelOwner ChannelManager::CreateChannelInternal( |
| + const Config& config, |
| + RtcEventLog* const event_log) { |
| Channel* channel; |
| - Channel::CreateChannel(channel, ++last_channel_id_, instance_id_, config); |
| + Channel::CreateChannel(channel, ++last_channel_id_, instance_id_, event_log, |
| + config); |
| ChannelOwner channel_owner(channel); |
| CriticalSectionScoped crit(lock_.get()); |