Title: [259751] trunk/Source/WebCore
- Revision
- 259751
- Author
- [email protected]
- Date
- 2020-04-08 13:06:53 -0700 (Wed, 08 Apr 2020)
Log Message
Additional cleanup from "Hit test with clipPath referencing parent element causes infinite recursion"
https://bugs.webkit.org/show_bug.cgi?id=210203
<rdar://problem/60002347>
Reviewed by Geoffrey Garen.
As suggested from the review in bug #209773, this incorporates some additional cleanup, including making the
SVGHitTestCycleDetectionScope constructor explicit, and clarifying the add/remove with the WeakHashSet, since
WeakPtr's operator* returns a reference to the template type (which is what we need).
No new tests as this is covered by existing tests and there are no functional changes.
* rendering/svg/SVGRenderSupport.cpp:
(WebCore::SVGHitTestCycleDetectionScope::SVGHitTestCycleDetectionScope):
(WebCore::SVGHitTestCycleDetectionScope::~SVGHitTestCycleDetectionScope):
* rendering/svg/SVGRenderSupport.h:
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (259750 => 259751)
--- trunk/Source/WebCore/ChangeLog 2020-04-08 20:05:06 UTC (rev 259750)
+++ trunk/Source/WebCore/ChangeLog 2020-04-08 20:06:53 UTC (rev 259751)
@@ -1,3 +1,22 @@
+2020-04-08 Doug Kelly <[email protected]>
+
+ Additional cleanup from "Hit test with clipPath referencing parent element causes infinite recursion"
+ https://bugs.webkit.org/show_bug.cgi?id=210203
+ <rdar://problem/60002347>
+
+ Reviewed by Geoffrey Garen.
+
+ As suggested from the review in bug #209773, this incorporates some additional cleanup, including making the
+ SVGHitTestCycleDetectionScope constructor explicit, and clarifying the add/remove with the WeakHashSet, since
+ WeakPtr's operator* returns a reference to the template type (which is what we need).
+
+ No new tests as this is covered by existing tests and there are no functional changes.
+
+ * rendering/svg/SVGRenderSupport.cpp:
+ (WebCore::SVGHitTestCycleDetectionScope::SVGHitTestCycleDetectionScope):
+ (WebCore::SVGHitTestCycleDetectionScope::~SVGHitTestCycleDetectionScope):
+ * rendering/svg/SVGRenderSupport.h:
+
2020-04-08 Devin Rousso <[email protected]>
Web Inspector: Storage: cannot clear out multiple or all local storage entries
Modified: trunk/Source/WebCore/rendering/svg/SVGRenderSupport.cpp (259750 => 259751)
--- trunk/Source/WebCore/rendering/svg/SVGRenderSupport.cpp 2020-04-08 20:05:06 UTC (rev 259750)
+++ trunk/Source/WebCore/rendering/svg/SVGRenderSupport.cpp 2020-04-08 20:06:53 UTC (rev 259751)
@@ -512,13 +512,13 @@
SVGHitTestCycleDetectionScope::SVGHitTestCycleDetectionScope(const RenderElement& element)
{
m_element = makeWeakPtr(&element);
- auto result = visitedElements().add(m_element.get());
+ auto result = visitedElements().add(*m_element);
ASSERT_UNUSED(result, result.isNewEntry);
}
SVGHitTestCycleDetectionScope::~SVGHitTestCycleDetectionScope()
{
- bool result = visitedElements().remove(*m_element.get());
+ bool result = visitedElements().remove(*m_element);
ASSERT_UNUSED(result, result);
}
Modified: trunk/Source/WebCore/rendering/svg/SVGRenderSupport.h (259750 => 259751)
--- trunk/Source/WebCore/rendering/svg/SVGRenderSupport.h 2020-04-08 20:05:06 UTC (rev 259750)
+++ trunk/Source/WebCore/rendering/svg/SVGRenderSupport.h 2020-04-08 20:06:53 UTC (rev 259751)
@@ -98,7 +98,7 @@
class SVGHitTestCycleDetectionScope {
WTF_MAKE_NONCOPYABLE(SVGHitTestCycleDetectionScope);
public:
- SVGHitTestCycleDetectionScope(const RenderElement&);
+ explicit SVGHitTestCycleDetectionScope(const RenderElement&);
~SVGHitTestCycleDetectionScope();
static bool isEmpty();
static bool isVisiting(const RenderElement&);
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes