Closed Bug 317869 Opened 20 years ago Closed 20 years ago

CNavDtd::GetMostDerivedIID returns nsIDTD's IID

Categories

(Core :: DOM: HTML Parser, defect, P2)

defect

Tracking

()

RESOLVED FIXED
mozilla1.9alpha1

People

(Reporter: neil, Assigned: mrbkap)

Details

Attachments

(1 file, 1 obsolete file)

nsExpatDriver::GetMostDerivedIID retuns nsIDTD's IID. nsViewSourceHTML::GetMostDerivedIID returns its own custom IID. However CNavDtd::GetMostDerivedIID tries to return NS_GET_IID(CNavDtd) which happens to resolve to nsIDTD's IID. Now although I could not find any history for it, given the implementation of QueryInterface and CDTDFinder I guess that CNavDtd should have its own ID, along the lines of nsViewSourceHTML.
My recent cleanup accidentally removed CNavDTD's IID.
Status: NEW → ASSIGNED
Priority: -- → P2
Target Milestone: --- → mozilla1.9alpha
Attached patch Put it backSplinter Review
Attachment #204235 - Flags: superreview?(jst)
Attachment #204235 - Flags: review?(jst)
Attached patch Don't put it back (obsolete) — Splinter Review
The point being that CNavDTD isn't an interface, so shouldn't have an accessor. In fact since nobody actually calls QueryInterface for NS_INAVHTML_DTD_IID that second hunk could be changed to NS_IMPL_ISUPPORTS1(CNavDTD, nsIDTD) instead.
Attachment #204245 - Flags: superreview?(jst)
Attachment #204245 - Flags: review?(mrbkap)
Comment on attachment 204245 [details] [diff] [review] Don't put it back D'oh, I just spotted that you do need to be able to QI to the class :-[
Attachment #204245 - Attachment is obsolete: true
Attachment #204245 - Flags: superreview?(jst)
Attachment #204245 - Flags: review?(mrbkap)
The other problem is that we currently rely on GetMostDerivedIID to select the correct DTD (I'm not exactly sure why my checkin didn't break everything). I'll try to work on removing this crazyness at some point.
Comment on attachment 204235 [details] [diff] [review] Put it back r+sr=jst
Attachment #204235 - Flags: superreview?(jst)
Attachment #204235 - Flags: superreview+
Attachment #204235 - Flags: review?(jst)
Attachment #204235 - Flags: review+
Checked in.
Status: ASSIGNED → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: