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

Unified Diff: Source/core/rendering/HitTestResult.cpp

Issue 26168008: [blink] Avoid null pointer dereference in HitTestResult::isMisspelled() (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Add expectations. Created 6 years, 10 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
Index: Source/core/rendering/HitTestResult.cpp
diff --git a/Source/core/rendering/HitTestResult.cpp b/Source/core/rendering/HitTestResult.cpp
index ac573ea9cd33a44a8d8eb126017e452b81b5896b..cb2458dc1b83265141a575f1b31084befc20ee5c 100644
--- a/Source/core/rendering/HitTestResult.cpp
+++ b/Source/core/rendering/HitTestResult.cpp
@@ -347,7 +347,7 @@ bool HitTestResult::isLiveLink() const
bool HitTestResult::isMisspelled() const
{
- if (!targetNode())
+ if (!targetNode() || !targetNode()->renderer())
eseidel 2014/02/25 00:30:02 I'm surprised that we'd have a HitTestResult which
please use gerrit instead 2014/02/25 01:14:53 So was I. :-)
return false;
VisiblePosition pos(targetNode()->renderer()->positionForPoint(localPoint()));
if (pos.isNull())

Powered by Google App Engine
This is Rietveld 408576698