Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(293)

Side by Side Diff: mojo/environment/default_run_loop_impl.cc

Issue 883583005: Copy build changes to compile mojo::AsyncWaiter to the chromium repo. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « mojo/environment/BUILD.gn ('k') | mojo/mojo_base.gyp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "mojo/environment/default_run_loop_impl.h" 5 #include "mojo/environment/default_run_loop_impl.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/message_loop/message_loop.h" 8 #include "base/message_loop/message_loop.h"
9 9
10 namespace mojo { 10 namespace mojo {
11 namespace internal { 11 namespace internal {
12 12
13 void InstantiateDefaultRunLoopImpl() { 13 void InstantiateDefaultRunLoopImpl() {
14 CHECK(!base::MessageLoop::current());
14 // Not leaked: accessible from |base::MessageLoop::current()|. 15 // Not leaked: accessible from |base::MessageLoop::current()|.
15 new base::MessageLoop(); 16 base::MessageLoop* message_loop = new base::MessageLoop();
17 CHECK_EQ(message_loop, base::MessageLoop::current());
16 } 18 }
17 19
18 void DestroyDefaultRunLoopImpl() { 20 void DestroyDefaultRunLoopImpl() {
21 CHECK(base::MessageLoop::current());
19 delete base::MessageLoop::current(); 22 delete base::MessageLoop::current();
23 CHECK(!base::MessageLoop::current());
20 } 24 }
21 25
22 } // namespace internal 26 } // namespace internal
23 } // namespace mojo 27 } // namespace mojo
OLDNEW
« no previous file with comments | « mojo/environment/BUILD.gn ('k') | mojo/mojo_base.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698