Chromium Code Reviews| Index: webrtc/base/messagequeue.h |
| diff --git a/webrtc/base/messagequeue.h b/webrtc/base/messagequeue.h |
| index d323283741cac23514799c7a15cc77b50e094dcd..35f13c644b706ff27535201ad51240c982306245 100644 |
| --- a/webrtc/base/messagequeue.h |
| +++ b/webrtc/base/messagequeue.h |
| @@ -175,8 +175,8 @@ class MessageQueue { |
| // init_queue and call DoInit() from their constructor to prevent races |
| // with the MessageQueueManager using the object while the vtable is still |
| // being created. |
| - explicit MessageQueue(SocketServer* ss = NULL, |
| - bool init_queue = true); |
| + MessageQueue(SocketServer* ss, bool init_queue); |
|
tommi
2016/04/27 12:45:25
Should this ctor be marked as deprecated?
Would it
danilchap
2016/04/27 15:08:55
It would make sense to remove MessageQueue depende
|
| + MessageQueue(std::unique_ptr<SocketServer> ss, bool init_queue); |
| // NOTE: SUBCLASSES OF MessageQueue THAT OVERRIDE Clear MUST CALL |
| // DoDestroy() IN THEIR DESTRUCTORS! This is required to avoid a data race |
| @@ -278,11 +278,11 @@ class MessageQueue { |
| private: |
| // The SocketServer is not owned by MessageQueue. |
| SocketServer* ss_ GUARDED_BY(ss_lock_); |
| - // If a server isn't supplied in the constructor, use this one. |
| - std::unique_ptr<SocketServer> default_ss_; |
| + // If caller pass socketserver with ownership. |
|
tommi
2016/04/27 12:45:25
nit: passes
or "Used if socketserver ownership lie
danilchap
2016/04/27 15:08:55
Done.
|
| + std::unique_ptr<SocketServer> own_ss_; |
| SharedExclusiveLock ss_lock_; |
| - RTC_DISALLOW_COPY_AND_ASSIGN(MessageQueue); |
| + RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(MessageQueue); |
| }; |
| } // namespace rtc |