Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(332)

Unified Diff: content/browser/renderer_host/render_widget_host_view_android.cc

Issue 677423003: Null check content view core before using it. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/renderer_host/render_widget_host_view_android.cc
diff --git a/content/browser/renderer_host/render_widget_host_view_android.cc b/content/browser/renderer_host/render_widget_host_view_android.cc
index af88a1b5ec0568e78b2632ca7d2f6db0b6eb94e4..1e0ff6dc22f3011143eca7c8a68dde4e423c4cb0 100644
--- a/content/browser/renderer_host/render_widget_host_view_android.cc
+++ b/content/browser/renderer_host/render_widget_host_view_android.cc
@@ -1116,6 +1116,10 @@ void RenderWidgetHostViewAndroid::SynchronousFrameMetadata(
OnFrameMetadataUpdated(frame_metadata);
ComputeContentsSize(frame_metadata);
+ // Content view core may possibly be destructed at this time.
boliu 2014/10/27 22:19:05 No need for comment
hush (inactive) 2014/10/27 22:24:03 Done.
+ if (content_view_core_ == NULL)
boliu 2014/10/27 22:19:05 if (!content_view_core_) And I think you can put
hush (inactive) 2014/10/27 22:24:03 Done.
+ return;
+
// DevTools ScreenCast support for Android WebView.
WebContents* web_contents = content_view_core_->GetWebContents();
if (DevToolsAgentHost::HasFor(web_contents)) {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698