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

Unified Diff: Source/core/fetch/FontResource.cpp

Issue 124943003: Remove 'String::append' from some of the blink source. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Incorporated review comments Created 6 years, 11 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/fetch/FontResource.cpp
diff --git a/Source/core/fetch/FontResource.cpp b/Source/core/fetch/FontResource.cpp
old mode 100644
new mode 100755
index 0fdbcc1d39e9a76f602f07f8dc2a14315522a5f4..319a2c0e5f4a3fe3b8e33e4f422cf197b59142c0
--- a/Source/core/fetch/FontResource.cpp
+++ b/Source/core/fetch/FontResource.cpp
@@ -110,10 +110,11 @@ bool FontResource::ensureSVGFontData()
m_externalSVGDocument = SVGDocument::create();
OwnPtr<TextResourceDecoder> decoder = TextResourceDecoder::create("application/xml");
- String svgSource = decoder->decode(m_data->data(), m_data->size());
+ StringBuilder svgSource;
+ svgSource.append(decoder->decode(m_data->data(), m_data->size()));
svgSource.append(decoder->flush());
- m_externalSVGDocument->setContent(svgSource);
+ m_externalSVGDocument->setContent(svgSource.toString());
if (decoder->sawError())
m_externalSVGDocument = 0;

Powered by Google App Engine
This is Rietveld 408576698