Add the GPU process as a sandbox broker peer. (bug 1289895, r=bobowen)
authorDavid Anderson <danderson@mozilla.com>
Wed, 27 Jul 2016 23:17:54 -0700
changeset 349099 003c650290a078c27d5cd2a495ae7a42ccc41598
parent 349098 43cf27f0e2edb5136c1fa3fe415841f52ee62ec9
child 349100 0bea94bc88114b495b5a380a99cf680c9b6cd5b8
push id1230
push userjlund@mozilla.com
push dateMon, 31 Oct 2016 18:13:35 +0000
treeherdermozilla-release@5e06e3766db2 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbobowen
bugs1289895
milestone50.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Add the GPU process as a sandbox broker peer. (bug 1289895, r=bobowen)
ipc/glue/GeckoChildProcessHost.cpp
--- a/ipc/glue/GeckoChildProcessHost.cpp
+++ b/ipc/glue/GeckoChildProcessHost.cpp
@@ -1120,19 +1120,20 @@ GeckoChildProcessHost::PerformAsyncLaunc
         cmdLine.command_line_string().c_str());
     }
   } else
 #endif
   {
     base::LaunchApp(cmdLine, false, false, &process);
 
 #ifdef MOZ_SANDBOX
-    // We need to be able to duplicate handles to non-sandboxed content and GMP
-    // processes, so add it as a target peer.
+    // We need to be able to duplicate handles to some types of non-sandboxed
+    // child processes.
     if (mProcessType == GeckoProcessType_Content ||
+        mProcessType == GeckoProcessType_GPU ||
         mProcessType == GeckoProcessType_GMPlugin) {
       if (!mSandboxBroker.AddTargetPeer(process)) {
         NS_WARNING("Failed to add content process as target peer.");
       }
     }
 #endif
   }