Closed Bug 460248 Opened 11 years ago Closed 11 years ago

reftest bugs/411059-1.html and bugs/450670-1.html fails with some profiles

Categories

(Core :: Layout, defect)

x86
Linux
defect
Not set

Tracking

()

RESOLVED FIXED

People

(Reporter: mats, Assigned: mats)

Details

Attachments

(2 files)

Attached patch Patch rev. 1Splinter Review
The problem seems to be that there's a BOM in these files which
isn't present in the corresponding -ref.html file.
Attachment #343379 - Flags: review?(roc)
Another reftest that fails for me is bugs/306630-1.html:
<frame src="javascript:'frame1'">
This results in font-family:sans-serif on the <html> element

in bugs/306630-1-ref.html:
<frame src="data:text/html,frame1">
This results in font-family:serif on the <html> element

Not sure why that happens... or how to fix it.  script?
Assignee: nobody → mats.palmgren
Dunno about that one. But thanks for doing this --- it's great to cut down the reftest noise.
With a little help from DOMI I see that the javascript: documents have characterSet="ISO-8859-1" and the data: documents are "windows-1251"
(which triggers the different font).
In both cases the outermost (frameset) document is "windows-1251".

I don't see why javascript: and data: should have different behaviour
like that since they both generate text/html documents.  Is this a bug?
javascript: will create ISO-8859-1 documents for compat reasons if the returned string could be considered ISO-8859-1.  See http://bonsai.mozilla.org/cvsblame.cgi?file=mozilla/dom/src/jsurl/nsJSProtocolHandler.cpp&rev=1.151&mark=352-369#345

data: on the other hand just creates an HTML document and then uses the normal rules for determining its charset (including inheriting from parent, etc).  If you really want a particular charset out of a data: document, just specify the charset in the data: URL?
I pushed this as changeset 99dbf3b2688b.
Boris, thanks for the explanation and fix.
http://hg.mozilla.org/mozilla-central/rev/58933c1b4994

-> FIXED
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.