Fix a bug where killing pages doesn't yield a sad-tab

The determination of whether or not to put up a sad tab page is made
based on the termination status of the renderer process.

The termination status of the renderer process is checked when
the channel between the browser and the renderer stops working.

There is a race here because there is no reason to believe that the
renderer process has finished terminating at the time that the
browser detects that its channel to the renderer is dead.

If renderer process is believed to be still running at the moment when
the decision to put up the sad tab page is taken, then no sad tab will
be put up, the view of the renderer will be removed (eventually), and
a transparent window will result.

This bug was previously fixed on Linux with with
https://chromiumcodereview.appspot.com/11316261
this patch expands that fix to Mac.

In particular, if the renderer process is known to be dead, wait for the
process to terminate before taking its termination status. To be sure
that the browser does not wait forever on a renderer that is not exiting,
send a kill signal to the renderer before doing the wait.

BUG=167538

Review URL: https://chromiumcodereview.appspot.com/23866011

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@223526 0039d316-1c4b-4281-b951-d872f2087c98


CrOS-Libchrome-Original-Commit: 0dac68b42cf4742c6e3d03dfaa14d2aa1ada0ea1
2 files changed
tree: bda4c5dcfb62e7068fedae9ecbb585a2a4a8ec02
  1. base/
  2. build/
  3. components/
  4. dbus/
  5. ipc/
  6. mojo/
  7. testing/
  8. third_party/
  9. ui/