summaryrefslogtreecommitdiffstats
path: root/content
diff options
context:
space:
mode:
Diffstat (limited to 'content')
-rw-r--r--content/browser/browser_child_process_host.cc4
-rw-r--r--content/browser/browser_child_process_host.h10
-rw-r--r--content/public/browser/notification_types.h7
3 files changed, 4 insertions, 17 deletions
diff --git a/content/browser/browser_child_process_host.cc b/content/browser/browser_child_process_host.cc
index 3e56b6e..7744153 100644
--- a/content/browser/browser_child_process_host.cc
+++ b/content/browser/browser_child_process_host.cc
@@ -131,6 +131,8 @@ void BrowserChildProcessHost::Notify(int type) {
base::TerminationStatus BrowserChildProcessHost::GetChildTerminationStatus(
int* exit_code) {
+ if (!child_process_.get()) // If the delegate doesn't use Launch() helper.
+ return base::GetTerminationStatus(handle(), exit_code);
return child_process_->GetChildTerminationStatus(exit_code);
}
@@ -174,9 +176,7 @@ void BrowserChildProcessHost::OnChildDisconnected() {
break;
}
case base::TERMINATION_STATUS_PROCESS_WAS_KILLED: {
- OnProcessWasKilled(exit_code);
// Report that this child process was killed.
- Notify(content::NOTIFICATION_CHILD_PROCESS_WAS_KILLED);
UMA_HISTOGRAM_ENUMERATION("ChildProcess.Killed",
this->type(),
content::PROCESS_TYPE_MAX);
diff --git a/content/browser/browser_child_process_host.h b/content/browser/browser_child_process_host.h
index 97edf84..2abb0bf 100644
--- a/content/browser/browser_child_process_host.h
+++ b/content/browser/browser_child_process_host.h
@@ -99,19 +99,13 @@ class CONTENT_EXPORT BrowserChildProcessHost :
// GetExitCodeProcess()).
virtual void OnProcessCrashed(int exit_code) {}
- // Derived classes can override this to know if the process was
- // killed. |exit_code| is the status returned when the process
- // was killed (for posix, as returned from waitpid(), for Windows,
- // as returned from GetExitCodeProcess()).
- virtual void OnProcessWasKilled(int exit_code) {}
-
// Returns the termination status of a child. |exit_code| is the
// status returned when the process exited (for posix, as returned
// from waitpid(), for Windows, as returned from
// GetExitCodeProcess()). |exit_code| may be NULL.
- virtual base::TerminationStatus GetChildTerminationStatus(int* exit_code);
+ base::TerminationStatus GetChildTerminationStatus(int* exit_code);
- // ChildProcessHostDelegate implementation:
+ // Overrides from ChildProcessHost
virtual bool CanShutdown() OVERRIDE;
virtual void OnChildDisconnected() OVERRIDE;
virtual void ShutdownStarted() OVERRIDE;
diff --git a/content/public/browser/notification_types.h b/content/public/browser/notification_types.h
index aa29994..970a50e 100644
--- a/content/public/browser/notification_types.h
+++ b/content/public/browser/notification_types.h
@@ -391,13 +391,6 @@ enum NotificationType {
// a Details<content::ChildProcessData>.
NOTIFICATION_CHILD_PROCESS_CRASHED,
- // This message is sent when a child process disappears
- // unexpectedly as a result of a termination signal. There is no
- // usable source, since it is sent from an ephemeral task;
- // register for AllSources() to receive this notification. The
- // details are in a Details<content::ChildProcessData>.
- NOTIFICATION_CHILD_PROCESS_WAS_KILLED,
-
// This message indicates that an instance of a particular child was
// created in a page. (If one page contains several regions rendered by
// the same child, this notification will occur once for each region