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 <stddef.h> | 7 #include <stddef.h> |
8 #include <stdlib.h> | 8 #include <stdlib.h> |
9 #include <string.h> | 9 #include <string.h> |
10 | 10 |
(...skipping 457 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
468 // - We do not override the signal handlers so that we can get | 468 // - We do not override the signal handlers so that we can get |
469 // stack trace when crashing. | 469 // stack trace when crashing. |
470 // - The ipc_fd is passed through the Java service. | 470 // - The ipc_fd is passed through the Java service. |
471 // Thus, these are all disabled. | 471 // Thus, these are all disabled. |
472 #if !defined(OS_ANDROID) | 472 #if !defined(OS_ANDROID) |
473 // Set C library locale to make sure CommandLine can parse argument values | 473 // Set C library locale to make sure CommandLine can parse argument values |
474 // in correct encoding. | 474 // in correct encoding. |
475 setlocale(LC_ALL, ""); | 475 setlocale(LC_ALL, ""); |
476 | 476 |
477 SetupSignalHandlers(); | 477 SetupSignalHandlers(); |
478 g_fds->Set(kPrimaryIPCChannel, | |
479 kPrimaryIPCChannel + base::GlobalDescriptors::kBaseDescriptor); | |
480 g_fds->Set(kMojoIPCChannel, | 478 g_fds->Set(kMojoIPCChannel, |
481 kMojoIPCChannel + base::GlobalDescriptors::kBaseDescriptor); | 479 kMojoIPCChannel + base::GlobalDescriptors::kBaseDescriptor); |
482 #endif // !OS_ANDROID | 480 #endif // !OS_ANDROID |
483 | 481 |
484 #if defined(OS_LINUX) || defined(OS_OPENBSD) | 482 #if defined(OS_LINUX) || defined(OS_OPENBSD) |
485 g_fds->Set(kCrashDumpSignal, | 483 g_fds->Set(kCrashDumpSignal, |
486 kCrashDumpSignal + base::GlobalDescriptors::kBaseDescriptor); | 484 kCrashDumpSignal + base::GlobalDescriptors::kBaseDescriptor); |
487 #endif // OS_LINUX || OS_OPENBSD | 485 #endif // OS_LINUX || OS_OPENBSD |
488 | 486 |
489 | 487 |
(...skipping 342 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
832 | 830 |
833 DISALLOW_COPY_AND_ASSIGN(ContentMainRunnerImpl); | 831 DISALLOW_COPY_AND_ASSIGN(ContentMainRunnerImpl); |
834 }; | 832 }; |
835 | 833 |
836 // static | 834 // static |
837 ContentMainRunner* ContentMainRunner::Create() { | 835 ContentMainRunner* ContentMainRunner::Create() { |
838 return new ContentMainRunnerImpl(); | 836 return new ContentMainRunnerImpl(); |
839 } | 837 } |
840 | 838 |
841 } // namespace content | 839 } // namespace content |
OLD | NEW |