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

Unified Diff: Source/core/html/parser/HTMLEntityParser.cpp

Issue 1311043004: Revert of SegmentedString::push() should always push a char in front (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 4 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/html/parser/HTMLEntityParser.h ('k') | Source/core/html/parser/HTMLEntityParserTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/parser/HTMLEntityParser.cpp
diff --git a/Source/core/html/parser/HTMLEntityParser.cpp b/Source/core/html/parser/HTMLEntityParser.cpp
index 62167ef4103e2cb8f0c29c8f2ecc792389b364a8..dc30c83715f4f72ba2b92a598ad4d987b51370c8 100644
--- a/Source/core/html/parser/HTMLEntityParser.cpp
+++ b/Source/core/html/parser/HTMLEntityParser.cpp
@@ -95,8 +95,8 @@
if (consumedCharacters.size() == 1)
source.push(consumedCharacters[0]);
else if (consumedCharacters.size() == 2) {
+ source.push(consumedCharacters[0]);
source.push(consumedCharacters[1]);
- source.push(consumedCharacters[0]);
} else
source.prepend(SegmentedString(String(consumedCharacters)));
}
@@ -212,8 +212,8 @@
entityState = Hex;
continue;
}
+ source.push('#');
source.push('x');
- source.push('#');
return false;
}
case MaybeHexUpperCaseX: {
@@ -221,8 +221,8 @@
entityState = Hex;
continue;
}
+ source.push('#');
source.push('X');
- source.push('#');
return false;
}
case Hex: {
« no previous file with comments | « Source/core/html/parser/HTMLEntityParser.h ('k') | Source/core/html/parser/HTMLEntityParserTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698