OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "content/public/app/content_main_runner.h" | 5 #include "content/public/app/content_main_runner.h" |
6 | 6 |
7 #include <stdlib.h> | 7 #include <stdlib.h> |
8 | 8 |
9 #include "base/allocator/allocator_extension.h" | 9 #include "base/allocator/allocator_extension.h" |
10 #include "base/at_exit.h" | 10 #include "base/at_exit.h" |
(...skipping 762 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
773 DCHECK(!is_shutdown_); | 773 DCHECK(!is_shutdown_); |
774 | 774 |
775 if (completed_basic_startup_ && delegate_) { | 775 if (completed_basic_startup_ && delegate_) { |
776 const CommandLine& command_line = *CommandLine::ForCurrentProcess(); | 776 const CommandLine& command_line = *CommandLine::ForCurrentProcess(); |
777 std::string process_type = | 777 std::string process_type = |
778 command_line.GetSwitchValueASCII(switches::kProcessType); | 778 command_line.GetSwitchValueASCII(switches::kProcessType); |
779 | 779 |
780 delegate_->ProcessExiting(process_type); | 780 delegate_->ProcessExiting(process_type); |
781 } | 781 } |
782 | 782 |
783 #if !defined(OS_IOS) | |
784 ShutdownMojo(); | |
785 #endif | |
786 | |
787 #if defined(OS_WIN) | 783 #if defined(OS_WIN) |
788 #ifdef _CRTDBG_MAP_ALLOC | 784 #ifdef _CRTDBG_MAP_ALLOC |
789 _CrtDumpMemoryLeaks(); | 785 _CrtDumpMemoryLeaks(); |
790 #endif // _CRTDBG_MAP_ALLOC | 786 #endif // _CRTDBG_MAP_ALLOC |
791 | 787 |
792 _Module.Term(); | 788 _Module.Term(); |
793 #endif // OS_WIN | 789 #endif // OS_WIN |
794 | 790 |
795 #if defined(OS_MACOSX) | 791 #if defined(OS_MACOSX) |
796 autorelease_pool_.reset(NULL); | 792 autorelease_pool_.reset(NULL); |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
829 | 825 |
830 DISALLOW_COPY_AND_ASSIGN(ContentMainRunnerImpl); | 826 DISALLOW_COPY_AND_ASSIGN(ContentMainRunnerImpl); |
831 }; | 827 }; |
832 | 828 |
833 // static | 829 // static |
834 ContentMainRunner* ContentMainRunner::Create() { | 830 ContentMainRunner* ContentMainRunner::Create() { |
835 return new ContentMainRunnerImpl(); | 831 return new ContentMainRunnerImpl(); |
836 } | 832 } |
837 | 833 |
838 } // namespace content | 834 } // namespace content |
OLD | NEW |