diff options
author | jam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-05-15 23:06:07 +0000 |
---|---|---|
committer | jam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-05-15 23:06:07 +0000 |
commit | ef2f6ba19e773ea58b8d6b26ea80bcf6c357ea7d (patch) | |
tree | f18f441d80b4b05ad3e6bcde476fd6461e00742e /ipc/ipc_message.h | |
parent | 5a05b1de6bb31e66f570b320b6b507e0e2d5798b (diff) | |
download | chromium_src-ef2f6ba19e773ea58b8d6b26ea80bcf6c357ea7d.zip chromium_src-ef2f6ba19e773ea58b8d6b26ea80bcf6c357ea7d.tar.gz chromium_src-ef2f6ba19e773ea58b8d6b26ea80bcf6c357ea7d.tar.bz2 |
Ensure that any IPC sent from a child process that couldn't be deserialized causes that process to be killed.
Today we do this only for a subset of IPCs and not all process types.
R=jar@chromium.org, tsepez@chromium.org
Review URL: https://codereview.chromium.org/283313002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@270839 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ipc/ipc_message.h')
-rw-r--r-- | ipc/ipc_message.h | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/ipc/ipc_message.h b/ipc/ipc_message.h index ea6cda6..e4b6208 100644 --- a/ipc/ipc_message.h +++ b/ipc/ipc_message.h @@ -121,6 +121,14 @@ class IPC_EXPORT Message : public Pickle { return (header()->flags & PUMPING_MSGS_BIT) != 0; } + void set_dispatch_error() const { + dispatch_error_ = true; + } + + bool dispatch_error() const { + return dispatch_error_; + } + uint32 type() const { return header()->type; } @@ -236,7 +244,10 @@ class IPC_EXPORT Message : public Pickle { return headerT<Header>(); } - void InitLoggingVariables(); + void Init(); + + // Used internally to support IPC::Listener::OnBadMessageReceived. + mutable bool dispatch_error_; #if defined(OS_POSIX) // The set of file descriptors associated with this message. |