Bug 118629 - parseHTMLInteger shouldn't upconvert 8-bit string
Summary: parseHTMLInteger shouldn't upconvert 8-bit string
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: DOM (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Ryosuke Niwa
URL:
Keywords: BlinkMergeCandidate
Depends on:
Blocks: 118641
  Show dependency treegraph
 
Reported: 2013-07-12 17:08 PDT by Ryosuke Niwa
Modified: 2013-07-13 08:33 PDT (History)
7 users (show)

See Also:


Attachments
Fixes the bug (1.47 KB, patch)
2013-07-12 18:49 PDT, Ryosuke Niwa
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ryosuke Niwa 2013-07-12 17:08:47 PDT
Merge https://chromium.googlesource.com/chromium/blink/+/e0ebab23e0c16b49dc90c9c39b8bbbf4f243a01e

--- a/Source/core/html/parser/HTMLParserIdioms.cpp
+++ b/Source/core/html/parser/HTMLParserIdioms.cpp
@@ -207,12 +207,12 @@
     // Step 1
     // Step 2
     unsigned length = input.length();
-    if (length && input.is8Bit()) {
+    if (!length || input.is8Bit()) {
         const LChar* start = input.characters8();
         return parseHTMLIntegerInternal(start, start + length, value);
     }
 
-    const UChar* start = input.bloatedCharacters();
+    const UChar* start = input.characters16();
     return parseHTMLIntegerInternal(start, start + length, value);
 }
Comment 1 Ryosuke Niwa 2013-07-12 18:49:35 PDT
Created attachment 206582 [details]
Fixes the bug
Comment 2 WebKit Commit Bot 2013-07-13 08:33:04 PDT
Comment on attachment 206582 [details]
Fixes the bug

Clearing flags on attachment: 206582

Committed r152610: <http://trac.webkit.org/changeset/152610>
Comment 3 WebKit Commit Bot 2013-07-13 08:33:06 PDT
All reviewed patches have been landed.  Closing bug.