Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(81)

Side by Side Diff: content/zygote/zygote_main_linux.cc

Issue 2755763002: media: Add build flag for CDM host verification (Closed)
Patch Set: fix cdm_host_file_path.cc Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « content/ppapi_plugin/ppapi_thread.cc ('k') | ppapi/features/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 65
66 #if BUILDFLAG(ENABLE_WEBRTC) 66 #if BUILDFLAG(ENABLE_WEBRTC)
67 #include "third_party/webrtc_overrides/init_webrtc.h" 67 #include "third_party/webrtc_overrides/init_webrtc.h"
68 #endif 68 #endif
69 69
70 #if defined(SANITIZER_COVERAGE) 70 #if defined(SANITIZER_COVERAGE)
71 #include <sanitizer/common_interface_defs.h> 71 #include <sanitizer/common_interface_defs.h>
72 #include <sanitizer/coverage_interface.h> 72 #include <sanitizer/coverage_interface.h>
73 #endif 73 #endif
74 74
75 #if BUILDFLAG(ENABLE_PEPPER_CDMS) 75 #if BUILDFLAG(ENABLE_CDM_HOST_VERIFICATION)
76 #include "content/common/media/cdm_host_files.h" 76 #include "content/common/media/cdm_host_files.h"
77 #endif 77 #endif
78 78
79 namespace content { 79 namespace content {
80 80
81 namespace { 81 namespace {
82 82
83 base::LazyInstance<std::set<std::string>>::Leaky g_timezones = 83 base::LazyInstance<std::set<std::string>>::Leaky g_timezones =
84 LAZY_INSTANCE_INITIALIZER; 84 LAZY_INSTANCE_INITIALIZER;
85 base::LazyInstance<base::Lock>::Leaky g_timezones_lock = 85 base::LazyInstance<base::Lock>::Leaky g_timezones_lock =
(...skipping 274 matching lines...) Expand 10 before | Expand all | Expand 10 after
360 RAND_set_urandom_fd(base::GetUrandomFD()); 360 RAND_set_urandom_fd(base::GetUrandomFD());
361 361
362 #if BUILDFLAG(ENABLE_PLUGINS) 362 #if BUILDFLAG(ENABLE_PLUGINS)
363 // Ensure access to the Pepper plugins before the sandbox is turned on. 363 // Ensure access to the Pepper plugins before the sandbox is turned on.
364 PreloadPepperPlugins(); 364 PreloadPepperPlugins();
365 #endif 365 #endif
366 #if BUILDFLAG(ENABLE_WEBRTC) 366 #if BUILDFLAG(ENABLE_WEBRTC)
367 InitializeWebRtcModule(); 367 InitializeWebRtcModule();
368 #endif 368 #endif
369 369
370 #if BUILDFLAG(ENABLE_PEPPER_CDMS) 370 #if BUILDFLAG(ENABLE_CDM_HOST_VERIFICATION)
371 CdmHostFiles::CreateGlobalInstance(); 371 CdmHostFiles::CreateGlobalInstance();
372 #endif 372 #endif
373 373
374 SkFontConfigInterface::SetGlobal( 374 SkFontConfigInterface::SetGlobal(
375 new FontConfigIPC(GetSandboxFD()))->unref(); 375 new FontConfigIPC(GetSandboxFD()))->unref();
376 376
377 // Set the android SkFontMgr for blink. We need to ensure this is done 377 // Set the android SkFontMgr for blink. We need to ensure this is done
378 // before the sandbox is initialized to allow the font manager to access 378 // before the sandbox is initialized to allow the font manager to access
379 // font configuration files on disk. 379 // font configuration files on disk.
380 if (base::CommandLine::ForCurrentProcess()->HasSwitch( 380 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
(...skipping 289 matching lines...) Expand 10 before | Expand all | Expand 10 after
670 const bool namespace_sandbox_engaged = sandbox_flags & kSandboxLinuxUserNS; 670 const bool namespace_sandbox_engaged = sandbox_flags & kSandboxLinuxUserNS;
671 CHECK_EQ(using_namespace_sandbox, namespace_sandbox_engaged); 671 CHECK_EQ(using_namespace_sandbox, namespace_sandbox_engaged);
672 672
673 Zygote zygote(sandbox_flags, std::move(fork_delegates), extra_children, 673 Zygote zygote(sandbox_flags, std::move(fork_delegates), extra_children,
674 extra_fds); 674 extra_fds);
675 // This function call can return multiple times, once per fork(). 675 // This function call can return multiple times, once per fork().
676 return zygote.ProcessRequests(); 676 return zygote.ProcessRequests();
677 } 677 }
678 678
679 } // namespace content 679 } // namespace content
OLDNEW
« no previous file with comments | « content/ppapi_plugin/ppapi_thread.cc ('k') | ppapi/features/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698