Bug 40725 - fast/encoding/japanese-encoding-mix.html fails on Tiger after enabling HTML5 Lexer
Summary: fast/encoding/japanese-encoding-mix.html fails on Tiger after enabling HTML5 ...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: 528+ (Nightly build)
Hardware: Macintosh OS X 10.4
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-06-16 11:28 PDT by Eric Seidel (no email)
Modified: 2010-08-11 19:38 PDT (History)
3 users (show)

See Also:


Attachments
Patch (2.96 KB, patch)
2010-06-16 19:15 PDT, Adam Barth
no flags Details | Formatted Diff | Diff
Patch for landing (3.17 KB, patch)
2010-08-11 11:09 PDT, Adam Barth
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Eric Seidel (no email) 2010-06-16 11:28:08 PDT
fast/encoding/japanese-encoding-mix.html fails on Tiger after enabling HTML5 Lexer

It looks like Tiger's decoders are not properly passing the --> off to the HTML Lexer so it never sees an end to the comment.

--- /Volumes/Data/WebKit-BuildSlave/tiger-intel-release/build/layout-test-results/fast/encoding/japanese-encoding-mix-expected.txt	2010-06-16 09:19:19.000000000 -0700
+++ /Volumes/Data/WebKit-BuildSlave/tiger-intel-release/build/layout-test-results/fast/encoding/japanese-encoding-mix-actual.txt	2010-06-16 09:19:19.000000000 -0700
@@ -1,5 +1,12 @@
-Some text here is encoded as EUC-JP, and some (in comment) as Shift_JIS. Since there is an explicit encoding declaration, auto-detection shouldn't change the encoding.
-
-ニッãƒãƒ³ãƒ†ãƒ¬ãƒ“
-
-Should be EUC-JP: EUC-JP
+layer at (0,0) size 800x600
+  RenderView at (0,0) size 800x600
+layer at (0,0) size 800x600
+  RenderBlock {HTML} at (0,0) size 800x600
+    RenderBody {BODY} at (8,8) size 784x576
+      RenderBlock {P} at (0,0) size 784x36
+        RenderText {#text} at (0,0) size 774x36
+          text run at (0,0) width 774: "Some text here is encoded as EUC-JP, and some (in comment) as Shift_JIS. Since there is an explicit encoding declaration,"
+          text run at (0,18) width 288: "auto-detection shouldn't change the encoding."
+      RenderBlock {P} at (0,52) size 784x21
+        RenderText {#text} at (0,3) size 112x18
+          text run at (0,3) width 112: "\x{30CB}\x{30C3}\x{30DD}\x{30F3}\x{30C6}\x{30EC}\x{30D3}"
Comment 1 Eric Seidel (no email) 2010-06-16 11:28:35 PDT
Bug 40661 is the same failure except for Qt (which also has different decoders).
Comment 2 Eric Seidel (no email) 2010-06-16 11:33:13 PDT
Skipping the test for now.  This bug should remain open to track the failure (at least for as long as Tiger is still a real platform... which can't be that much longer now).
Comment 3 Eric Seidel (no email) 2010-06-16 11:33:19 PDT
Committed r61266: <http://trac.webkit.org/changeset/61266>
Comment 4 Alexey Proskuryakov 2010-06-16 16:02:39 PDT
The fix would be to just add a space before --> to insulate the test from EUC-JP decoder differences.
Comment 5 Eric Seidel (no email) 2010-06-16 16:04:15 PDT
That's fine too.  Do we care about testing the encoder differences?
Comment 6 Alexey Proskuryakov 2010-06-16 16:23:23 PDT
I don't think we should try to test edge cases of complex decoders like this, unless we suspect that particular bugs may have security implications.
Comment 7 Adam Barth 2010-06-16 19:15:26 PDT
Created attachment 58952 [details]
Patch
Comment 8 Alexey Proskuryakov 2010-06-16 19:26:50 PDT
Comment on attachment 58952 [details]
Patch

 +          Qt and Tiger seem to have encoding problems that swallow the --
I think it's only one character after an invalid sequence that gets swallowed.

r=me
Comment 9 Adam Barth 2010-08-11 10:19:19 PDT
Comment on attachment 58952 [details]
Patch

Wow.  I don't think this was ever landed.  :(
Comment 10 WebKit Commit Bot 2010-08-11 10:55:56 PDT
Comment on attachment 58952 [details]
Patch

Rejecting patch 58952 from commit-queue.

Failed to run "[u'/Users/eseidel/Projects/CommitQueue/WebKitTools/Scripts/svn-apply', u'--reviewer', u'Alexey Proskuryakov', u'--force']" exit_code: 1
Parsed 4 diffs from patch file(s).
patching file LayoutTests/ChangeLog
Hunk #1 succeeded at 1 with fuzz 3.
patching file LayoutTests/fast/encoding/japanese-encoding-mix.html
patching file LayoutTests/platform/mac-tiger/Skipped
Hunk #1 FAILED at 194.
1 out of 1 hunk FAILED -- saving rejects to file LayoutTests/platform/mac-tiger/Skipped.rej
patching file LayoutTests/platform/qt/Skipped
Hunk #1 FAILED at 5417.
1 out of 1 hunk FAILED -- saving rejects to file LayoutTests/platform/qt/Skipped.rej

Full output: http://queues.webkit.org/results/3734061
Comment 11 Adam Barth 2010-08-11 11:09:45 PDT
Created attachment 64136 [details]
Patch for landing
Comment 12 WebKit Commit Bot 2010-08-11 19:38:13 PDT
Comment on attachment 64136 [details]
Patch for landing

Clearing flags on attachment: 64136

Committed r65211: <http://trac.webkit.org/changeset/65211>
Comment 13 WebKit Commit Bot 2010-08-11 19:38:18 PDT
All reviewed patches have been landed.  Closing bug.