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

Unified Diff: mojo/shell/context.cc

Issue 397733003: mojo: kill app_thread before unloading main app library and add tests (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: also service_manager_unittests Created 6 years, 5 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 | « mojo/shell/context.h ('k') | mojo/shell/desktop/mojo_main.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/shell/context.cc
diff --git a/mojo/shell/context.cc b/mojo/shell/context.cc
index 7400d1ce6cb7bbdff1d6db39f6064f1335697e7b..159e3230d5236cac5a603e8d8ead01ecc935dbf0 100644
--- a/mojo/shell/context.cc
+++ b/mojo/shell/context.cc
@@ -150,7 +150,7 @@ Context::Context()
#endif
}
-Context::~Context() {
+void Context::Shutdown() {
// mojo_view_manager uses native_viewport. Destroy mojo_view_manager first so
// that there aren't shutdown ordering issues. Once native viewport service is
// moved into its own process this can likely be nuked.
@@ -160,6 +160,11 @@ Context::~Context() {
GURL("mojo:mojo_view_manager"));
#endif
service_manager_.set_default_loader(scoped_ptr<ServiceLoader>());
+ service_manager_.TerminateShellConnections();
+}
+
+Context::~Context() {
+ Shutdown();
}
} // namespace shell
« no previous file with comments | « mojo/shell/context.h ('k') | mojo/shell/desktop/mojo_main.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698