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

Unified Diff: mojo/embedder/test_embedder.cc

Issue 216893005: Mojo: Move the handle table details out of CoreImpl into its own class. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix compile assert Created 6 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | mojo/mojo.gyp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/embedder/test_embedder.cc
diff --git a/mojo/embedder/test_embedder.cc b/mojo/embedder/test_embedder.cc
index 912a7ac25bbd34585f0beed68058b285a8568b31..855d1da4feecbc02a19a19a392c1d7e77cb9814f 100644
--- a/mojo/embedder/test_embedder.cc
+++ b/mojo/embedder/test_embedder.cc
@@ -7,6 +7,7 @@
#include "base/logging.h"
#include "base/macros.h"
#include "mojo/system/core_impl.h"
+#include "mojo/system/handle_table.h"
namespace mojo {
@@ -15,12 +16,15 @@ namespace internal {
bool ShutdownCheckNoLeaks(CoreImpl* core_impl) {
// No point in taking the lock.
- if (core_impl->handle_table_.empty())
+ const HandleTable::HandleToEntryMap& handle_to_entry_map =
+ core_impl->handle_table_.handle_to_entry_map_;
+
+ if (handle_to_entry_map.empty())
return true;
- for (CoreImpl::HandleTableMap::const_iterator it =
- core_impl->handle_table_.begin();
- it != core_impl->handle_table_.end();
+ for (HandleTable::HandleToEntryMap::const_iterator it =
+ handle_to_entry_map.begin();
+ it != handle_to_entry_map.end();
++it) {
LOG(ERROR) << "Mojo embedder shutdown: Leaking handle " << (*it).first;
}
« no previous file with comments | « no previous file | mojo/mojo.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698