Closed Bug 213416 Opened 21 years ago Closed 21 years ago

nsUnknownDecoder: [FIX]Should detect stuff starting with <HEAD> as HTML

Categories

(Core :: Networking, defect, P1)

defect

Tracking

()

VERIFIED FIXED
mozilla1.5beta

People

(Reporter: bzbarsky, Assigned: bzbarsky)

References

Details

(Keywords: fixed1.4.1, Whiteboard: checkwin, checklinux)

Attachments

(1 file)

Looks like we don't consider something that starts with "<HEAD>" to be HTML in
nsUnknownDecoder.... This is not really a good idea, since the <html> tag is
optional, and has caused trouble for some people already....
Attached patch Silly patchSplinter Review
Attachment #128235 - Flags: superreview?(darin)
Attachment #128235 - Flags: review?(cbiesinger)
Attachment #128235 - Flags: review?(cbiesinger) → review+
Priority: -- → P1
Summary: Should detect stuff starting with <HEAD> as HTML → [FIX]Should detect stuff starting with <HEAD> as HTML
Target Milestone: --- → mozilla1.5beta
Attachment #128235 - Flags: superreview?(darin) → superreview+
Fixed.
Status: NEW → RESOLVED
Closed: 21 years ago
Resolution: --- → FIXED
Comment on attachment 128235 [details] [diff] [review]
Silly patch

This is a very simple, safe change, and fixes a regression (we would normally
detect such pages as HTML in 1.3, but not in 1.4).  Could this please be
approved for the 1.4 branch?
Attachment #128235 - Flags: approval1.4.x?
Flags: blocking1.4.x?
Flags: blocking1.4.x?
bz: got two public files so I can try this out and verify?
Summary: [FIX]Should detect stuff starting with <HEAD> as HTML → nsUnknownDecoder: [FIX]Should detect stuff starting with <HEAD> as HTML
I have no webserver that I control, so no.  The simple way to test is to put the
following:

<head></head><body><h1>Heading</h1></body>

into a file with a name of "test" (no extensions), then load that via file://
Comment on attachment 128235 [details] [diff] [review]
Silly patch

a=mkaply
Attachment #128235 - Flags: approval1.4.x? → approval1.4.x+
please add fixed1.4.1 keyword when this is checked in.
Flags: blocking1.4.x+
Keywords: fixed1.4.1
Blocks: 224532
VERIFIED: Mac OS X, Mozilla 1.6b
Named the suggested file unknown and unknown.txt.

unknown, since it has no extension, did render as HTML.
unknownw.txt displayed as text.
Status: RESOLVED → VERIFIED
Whiteboard: checkwin, checklinux
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: