| 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 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 57 #include "content/common/pepper_plugin_list.h" | 57 #include "content/common/pepper_plugin_list.h" |
| 58 #include "content/public/common/pepper_plugin_info.h" | 58 #include "content/public/common/pepper_plugin_info.h" |
| 59 #endif | 59 #endif |
| 60 | 60 |
| 61 #if defined(ENABLE_WEBRTC) | 61 #if defined(ENABLE_WEBRTC) |
| 62 #include "third_party/libjingle/overrides/init_webrtc.h" | 62 #include "third_party/libjingle/overrides/init_webrtc.h" |
| 63 #endif | 63 #endif |
| 64 | 64 |
| 65 #if defined(ADDRESS_SANITIZER) | 65 #if defined(ADDRESS_SANITIZER) |
| 66 #include <sanitizer/asan_interface.h> | 66 #include <sanitizer/asan_interface.h> |
| 67 #include <sanitizer/coverage_interface.h> |
| 67 #endif | 68 #endif |
| 68 | 69 |
| 69 namespace content { | 70 namespace content { |
| 70 | 71 |
| 71 namespace { | 72 namespace { |
| 72 | 73 |
| 73 void DoChrootSignalHandler(int) { | 74 void DoChrootSignalHandler(int) { |
| 74 const int old_errno = errno; | 75 const int old_errno = errno; |
| 75 const char kFirstMessage[] = "Chroot signal handler called.\n"; | 76 const char kFirstMessage[] = "Chroot signal handler called.\n"; |
| 76 ignore_result(write(STDERR_FILENO, kFirstMessage, sizeof(kFirstMessage) - 1)); | 77 ignore_result(write(STDERR_FILENO, kFirstMessage, sizeof(kFirstMessage) - 1)); |
| (...skipping 563 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 640 bool setuid_sandbox_engaged = sandbox_flags & kSandboxLinuxSUID; | 641 bool setuid_sandbox_engaged = sandbox_flags & kSandboxLinuxSUID; |
| 641 CHECK_EQ(must_enable_setuid_sandbox, setuid_sandbox_engaged); | 642 CHECK_EQ(must_enable_setuid_sandbox, setuid_sandbox_engaged); |
| 642 | 643 |
| 643 Zygote zygote(sandbox_flags, fork_delegates.Pass(), extra_children, | 644 Zygote zygote(sandbox_flags, fork_delegates.Pass(), extra_children, |
| 644 extra_fds); | 645 extra_fds); |
| 645 // This function call can return multiple times, once per fork(). | 646 // This function call can return multiple times, once per fork(). |
| 646 return zygote.ProcessRequests(); | 647 return zygote.ProcessRequests(); |
| 647 } | 648 } |
| 648 | 649 |
| 649 } // namespace content | 650 } // namespace content |
| OLD | NEW |