summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsteveblock@chromium.org <steveblock@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-05-30 11:28:08 +0000
committersteveblock@chromium.org <steveblock@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-05-30 11:28:08 +0000
commit470bec6db2dae0f59b360facf4423caf15cd56b0 (patch)
tree67797a52b2430d77aa750f413d8ba9b6f4c67d1d
parentb6ebf078d2ada6bb2e226d58686cc9e7469b55fa (diff)
downloadchromium_src-470bec6db2dae0f59b360facf4423caf15cd56b0.zip
chromium_src-470bec6db2dae0f59b360facf4423caf15cd56b0.tar.gz
chromium_src-470bec6db2dae0f59b360facf4423caf15cd56b0.tar.bz2
Add a CHECK() in NPChannelBase::GetChannel() to help investigate crbug.com/97285
This will indicate whether the crash is because the NPChannelBase fails to find the named channel in its map, or whether it's because we try to re-initialize an existing channel with an invalid socket FD. BUG=97285 Review URL: https://chromiumcodereview.appspot.com/10447017 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@139521 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--content/common/np_channel_base.cc4
1 files changed, 4 insertions, 0 deletions
diff --git a/content/common/np_channel_base.cc b/content/common/np_channel_base.cc
index 2db501f..d9b2e42 100644
--- a/content/common/np_channel_base.cc
+++ b/content/common/np_channel_base.cc
@@ -35,6 +35,10 @@ NPChannelBase* NPChannelBase::GetChannel(
channel = factory();
} else {
channel = iter->second;
+#if defined(OS_POSIX)
+ // Investigation for crbug.com/97285.
+ CHECK(channel->channel_valid() || channel_handle.socket.fd != -1);
+#endif
}
DCHECK(channel != NULL);