Bug 16692 - Acid3 expects \u escapes to work in data: urls
Summary: Acid3 expects \u escapes to work in data: urls
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: Macintosh OS X 10.4
: P2 Normal
Assignee: Nobody
URL:
Keywords:
: 11464 (view as bug list)
Depends on:
Blocks:
 
Reported: 2008-01-01 01:26 PST by Eric Seidel (no email)
Modified: 2008-11-28 12:25 PST (History)
1 user (show)

See Also:


Attachments
test case (281 bytes, text/html)
2008-01-01 01:26 PST, Eric Seidel (no email)
no flags Details
Don't replace \ with / in data: urls (3.03 KB, patch)
2008-01-01 02:32 PST, Eric Seidel (no email)
ap: review+
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) 2008-01-01 01:26:19 PST
Acid3 expects \u escapes to work in data: urls

We seem to be escaping \'s as /'s before trying \u escapes.

See test case.  This should be an easy fix.

Firefox and opera pass this test, I have not tried WinIE.
Comment 1 Eric Seidel (no email) 2008-01-01 01:26:36 PST
Created attachment 18222 [details]
test case
Comment 2 Eric Seidel (no email) 2008-01-01 02:11:14 PST
I expect this is the problem right here:

KURL::init()

    // for compatibility with Win IE, we must treat backslashes as if they were slashes, as long as we're not dealing with the javascript: schema
    DeprecatedString substitutedRelative;
    bool shouldSubstituteBackslashes = relative.contains('\\') && !relative.startsWith("javascript:", false);
    if (shouldSubstituteBackslashes) {
        substitutedRelative = substituteBackslashes(relative);
    }

That check is obviously failing (or not getting hit for this code path).
Comment 3 Eric Seidel (no email) 2008-01-01 02:32:00 PST
Created attachment 18223 [details]
Don't replace \ with / in data: urls

 LayoutTests/ChangeLog                              |   10 ++++++++++
 .../loader/url-data-replace-backslash-expected.txt |    1 +
 .../fast/loader/url-data-replace-backslash.html    |   13 +++++++++++++
 WebCore/ChangeLog                                  |   12 ++++++++++++
 WebCore/platform/KURL.cpp                          |    5 ++---
 5 files changed, 38 insertions(+), 3 deletions(-)
Comment 4 Alexey Proskuryakov 2008-01-01 02:37:26 PST
Comment on attachment 18223 [details]
Don't replace \ with / in data: urls

r=me

\ No newline at end of file

Please add one :)
Comment 5 Eric Seidel (no email) 2008-01-01 02:41:28 PST
r29061
Comment 6 Alexey Proskuryakov 2008-11-28 12:25:35 PST
*** Bug 11464 has been marked as a duplicate of this bug. ***