Index: Source/core/rendering/svg/SVGTextMetrics.cpp |
diff --git a/Source/core/rendering/svg/SVGTextMetrics.cpp b/Source/core/rendering/svg/SVGTextMetrics.cpp |
index 26dbc4c75075827367b4c475970eae2c5c7d077a..687c93deb5f4c1851d41985aa48d1fe1408e8eb6 100644 |
--- a/Source/core/rendering/svg/SVGTextMetrics.cpp |
+++ b/Source/core/rendering/svg/SVGTextMetrics.cpp |
@@ -50,14 +50,11 @@ SVGTextMetrics::SVGTextMetrics(RenderSVGInlineText* textRenderer, const TextRun& |
ASSERT(scalingFactor); |
const Font& scaledFont = textRenderer->scaledFont(); |
- int length = 0; |
+ m_length = 0; |
// Calculate width/height using the scaled font, divide this result by the scalingFactor afterwards. |
- m_width = scaledFont.width(run, length, m_glyph) / scalingFactor; |
+ m_width = scaledFont.width(run, m_length, m_glyph) / scalingFactor; |
m_height = scaledFont.fontMetrics().floatHeight() / scalingFactor; |
- |
- ASSERT(length >= 0); |
- m_length = static_cast<unsigned>(length); |
} |
TextRun SVGTextMetrics::constructTextRun(RenderSVGInlineText* text, unsigned position, unsigned length) |