diff options
author | Carlos J. Puga Medina <cpm@FreeBSD.org> | 2017-01-16 22:48:27 +0000 |
---|---|---|
committer | Carlos J. Puga Medina <cpm@FreeBSD.org> | 2017-01-16 22:48:27 +0000 |
commit | 6dbfad2eb0314255340f744ef913b09fd33f8ed3 (patch) | |
tree | 2379146fde95ec494ba77d260c6c5d7747a28d42 /www/chromium/files/patch-content_browser_browser__main__loop.cc | |
parent | Update to 0.1.9 (diff) |
www/chromium: update to 55.0.2883.87
Reviewed by: rene
MFH: 2017Q1
Security: https://www.vuxml.org/freebsd/603fe0a1-bb26-11e6-8e5a-3065ec8fd3ec.html
Diffstat (limited to 'www/chromium/files/patch-content_browser_browser__main__loop.cc')
-rw-r--r-- | www/chromium/files/patch-content_browser_browser__main__loop.cc | 40 |
1 files changed, 25 insertions, 15 deletions
diff --git a/www/chromium/files/patch-content_browser_browser__main__loop.cc b/www/chromium/files/patch-content_browser_browser__main__loop.cc index a1281200bb34..574c2f933338 100644 --- a/www/chromium/files/patch-content_browser_browser__main__loop.cc +++ b/www/chromium/files/patch-content_browser_browser__main__loop.cc @@ -1,6 +1,17 @@ ---- content/browser/browser_main_loop.cc.orig 2016-07-20 22:03:24.000000000 +0300 -+++ content/browser/browser_main_loop.cc 2016-08-18 02:39:59.331387000 +0300 -@@ -203,7 +203,7 @@ +--- content/browser/browser_main_loop.cc.orig 2016-12-15 13:00:14.708308000 +0000 ++++ content/browser/browser_main_loop.cc 2016-12-15 13:05:18.516426000 +0000 +@@ -196,6 +196,10 @@ + #include "gpu/vulkan/vulkan_implementation.h" + #endif + ++#if defined(OS_BSD) ++#include "content/common/child_process_sandbox_support_impl_linux.h" ++#endif ++ + // One of the linux specific headers defines this as a macro. + #ifdef DestroyAll + #undef DestroyAll +@@ -204,7 +208,7 @@ namespace content { namespace { @@ -8,22 +19,21 @@ +#if defined(OS_POSIX) && !defined(OS_MACOSX) && !defined(OS_ANDROID) && !defined(OS_BSD) void SetupSandbox(const base::CommandLine& parsed_command_line) { TRACE_EVENT0("startup", "SetupSandbox"); - base::FilePath sandbox_binary; -@@ -467,7 +467,7 @@ + if (parsed_command_line.HasSwitch(switches::kNoZygote)) { +@@ -475,10 +479,15 @@ + void BrowserMainLoop::EarlyInitialization() { TRACE_EVENT0("startup", "BrowserMainLoop::EarlyInitialization"); - TRACK_SCOPED_REGION("Startup", "BrowserMainLoop::EarlyInitialization"); -#if defined(OS_POSIX) && !defined(OS_MACOSX) && !defined(OS_ANDROID) +#if defined(OS_POSIX) && !defined(OS_MACOSX) && !defined(OS_ANDROID) && !defined(OS_BSD) // No thread should be created before this call, as SetupSandbox() // will end-up using fork(). SetupSandbox(parsed_command_line_); -@@ -507,7 +507,7 @@ - // We use quite a few file descriptors for our IPC, and the default limit on - // the Mac is low (256), so bump it up. - base::SetFdLimit(1024); --#elif defined(OS_LINUX) -+#elif defined(OS_LINUX) || defined(OS_BSD) - // Same for Linux. The default various per distro, but it is 1024 on Fedora. - // Low soft limits combined with liberal use of file descriptors means power - // users can easily hit this limit with many open tabs. Bump up the limit to ++#elif defined(OS_BSD) ++ RenderSandboxHostLinux::GetInstance()->Init(); ++ base::FileHandleMappingVector fds_to_map; ++ const int sfd = RenderSandboxHostLinux::GetInstance()->GetRendererSocket(); ++ fds_to_map.push_back(std::make_pair(sfd, GetSandboxFD())); + #endif + + #if defined(USE_X11) |