| 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/zygote/zygote_main.h" | 5 #include "content/zygote/zygote_main.h" |
| 6 | 6 |
| 7 #include <dlfcn.h> | 7 #include <dlfcn.h> |
| 8 #include <fcntl.h> | 8 #include <fcntl.h> |
| 9 #include <pthread.h> | 9 #include <pthread.h> |
| 10 #include <signal.h> | 10 #include <signal.h> |
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 59 #include "content/common/pepper_plugin_list.h" | 59 #include "content/common/pepper_plugin_list.h" |
| 60 #include "content/public/common/pepper_plugin_info.h" | 60 #include "content/public/common/pepper_plugin_info.h" |
| 61 #endif | 61 #endif |
| 62 | 62 |
| 63 #if defined(ENABLE_WEBRTC) | 63 #if defined(ENABLE_WEBRTC) |
| 64 #include "third_party/libjingle/overrides/init_webrtc.h" | 64 #include "third_party/libjingle/overrides/init_webrtc.h" |
| 65 #endif | 65 #endif |
| 66 | 66 |
| 67 #if defined(ADDRESS_SANITIZER) | 67 #if defined(ADDRESS_SANITIZER) |
| 68 #include <sanitizer/asan_interface.h> | 68 #include <sanitizer/asan_interface.h> |
| 69 #include <sanitizer/coverage_interface.h> |
| 69 #endif | 70 #endif |
| 70 | 71 |
| 71 namespace content { | 72 namespace content { |
| 72 | 73 |
| 73 namespace { | 74 namespace { |
| 74 | 75 |
| 75 void DoChrootSignalHandler(int) { | 76 void DoChrootSignalHandler(int) { |
| 76 const int old_errno = errno; | 77 const int old_errno = errno; |
| 77 const char kFirstMessage[] = "Chroot signal handler called.\n"; | 78 const char kFirstMessage[] = "Chroot signal handler called.\n"; |
| 78 ignore_result(write(STDERR_FILENO, kFirstMessage, sizeof(kFirstMessage) - 1)); | 79 ignore_result(write(STDERR_FILENO, kFirstMessage, sizeof(kFirstMessage) - 1)); |
| (...skipping 571 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 650 bool setuid_sandbox_engaged = sandbox_flags & kSandboxLinuxSUID; | 651 bool setuid_sandbox_engaged = sandbox_flags & kSandboxLinuxSUID; |
| 651 CHECK_EQ(using_setuid_sandbox, setuid_sandbox_engaged); | 652 CHECK_EQ(using_setuid_sandbox, setuid_sandbox_engaged); |
| 652 | 653 |
| 653 Zygote zygote(sandbox_flags, fork_delegates.Pass(), extra_children, | 654 Zygote zygote(sandbox_flags, fork_delegates.Pass(), extra_children, |
| 654 extra_fds); | 655 extra_fds); |
| 655 // This function call can return multiple times, once per fork(). | 656 // This function call can return multiple times, once per fork(). |
| 656 return zygote.ProcessRequests(); | 657 return zygote.ProcessRequests(); |
| 657 } | 658 } |
| 658 | 659 |
| 659 } // namespace content | 660 } // namespace content |
| OLD | NEW |