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

Unified Diff: Source/core/rendering/svg/SVGTextRunRenderingContext.cpp

Issue 216563002: [SVG Fonts] Fix <font-face> element leak document (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: rebased Created 6 years, 8 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 | « Source/core/css/FontFace.cpp ('k') | Source/core/svg/SVGFontData.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/rendering/svg/SVGTextRunRenderingContext.cpp
diff --git a/Source/core/rendering/svg/SVGTextRunRenderingContext.cpp b/Source/core/rendering/svg/SVGTextRunRenderingContext.cpp
index fe7685b0d2e85ff96d410a2c13fc7fc1de8932b4..3c2b38925df950e1fab5258e5d7f852c4e1f0681 100644
--- a/Source/core/rendering/svg/SVGTextRunRenderingContext.cpp
+++ b/Source/core/rendering/svg/SVGTextRunRenderingContext.cpp
@@ -46,6 +46,10 @@ static inline const SVGFontData* svgFontAndFontFaceElementForFontData(const Simp
RefPtr<CustomFontData> customFontData = fontData->customFontData();
const SVGFontData* svgFontData = static_cast<const SVGFontData*>(customFontData.get());
+ // FIXME crbug.com/359380 : The current editing impl references the font after the svg font nodes are removed.
+ if (svgFontData->shouldSkipDrawing())
+ return 0;
+
fontFace = svgFontData->svgFontFaceElement();
ASSERT(fontFace);
« no previous file with comments | « Source/core/css/FontFace.cpp ('k') | Source/core/svg/SVGFontData.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698