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 <stdio.h> | 10 #include <stdio.h> |
11 #include <sys/socket.h> | 11 #include <sys/socket.h> |
12 #include <sys/stat.h> | 12 #include <sys/stat.h> |
13 #include <sys/types.h> | 13 #include <sys/types.h> |
14 #include <sys/wait.h> | 14 #include <sys/wait.h> |
15 #include <unistd.h> | 15 #include <unistd.h> |
16 | 16 |
17 #include "base/basictypes.h" | 17 #include "base/basictypes.h" |
18 #include "base/command_line.h" | 18 #include "base/command_line.h" |
19 #include "base/containers/hash_tables.h" | 19 #include "base/containers/hash_tables.h" |
20 #include "base/files/file_path.h" | 20 #include "base/files/file_path.h" |
21 #include "base/linux_util.h" | 21 #include "base/linux_util.h" |
22 #include "base/memory/scoped_ptr.h" | 22 #include "base/memory/scoped_ptr.h" |
23 #include "base/pickle.h" | 23 #include "base/pickle.h" |
24 #include "base/posix/eintr_wrapper.h" | 24 #include "base/posix/eintr_wrapper.h" |
25 #include "base/posix/unix_domain_socket_linux.h" | 25 #include "base/posix/unix_domain_socket_linux.h" |
26 #include "base/process_util.h" | |
27 #include "base/rand_util.h" | 26 #include "base/rand_util.h" |
28 #include "base/sys_info.h" | 27 #include "base/sys_info.h" |
29 #include "build/build_config.h" | 28 #include "build/build_config.h" |
30 #include "content/common/font_config_ipc_linux.h" | 29 #include "content/common/font_config_ipc_linux.h" |
31 #include "content/common/pepper_plugin_registry.h" | 30 #include "content/common/pepper_plugin_registry.h" |
32 #include "content/common/sandbox_linux.h" | 31 #include "content/common/sandbox_linux.h" |
33 #include "content/common/zygote_commands_linux.h" | 32 #include "content/common/zygote_commands_linux.h" |
34 #include "content/public/common/content_switches.h" | 33 #include "content/public/common/content_switches.h" |
35 #include "content/public/common/main_function_params.h" | 34 #include "content/public/common/main_function_params.h" |
36 #include "content/public/common/sandbox_linux.h" | 35 #include "content/public/common/sandbox_linux.h" |
(...skipping 431 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
468 } | 467 } |
469 | 468 |
470 int sandbox_flags = linux_sandbox->GetStatus(); | 469 int sandbox_flags = linux_sandbox->GetStatus(); |
471 | 470 |
472 Zygote zygote(sandbox_flags, forkdelegate); | 471 Zygote zygote(sandbox_flags, forkdelegate); |
473 // This function call can return multiple times, once per fork(). | 472 // This function call can return multiple times, once per fork(). |
474 return zygote.ProcessRequests(); | 473 return zygote.ProcessRequests(); |
475 } | 474 } |
476 | 475 |
477 } // namespace content | 476 } // namespace content |
OLD | NEW |