Closed Bug 174921 Opened 23 years ago Closed 1 year ago

casting in nsInMemoryDataSource is fishy

Categories

(Core Graveyard :: RDF, defect)

x86
Linux
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED INCOMPLETE

People

(Reporter: bzbarsky, Unassigned)

Details

InMemoryArcsEnumeratorImpl::ArcEnumerator puts a bunch of nsIRDFNode objects into an nsISupportsArray. After that, many callsites get them out and cast to nsIRDFResource.... If the objects are in fact nsIRDFResource objects, it may make sense to cast them on insertion to make it clear what's going on (and to allow the use of an nsCOMArray instead of nsISupportsArray). Of course there's the question of whether they are always nsIRDFResources...
QA Contact: tever → nobody
The property for an RDF arc (which is what's being put in the array here) is always a resource, so there shouldn't be any danger here. That said, the suggestion is valid.
waterson left the building
Assignee: waterson → nobody
QA Contact: nobody → core.rdf
Product: Core → Core Graveyard
Status: NEW → RESOLVED
Closed: 1 year ago
Resolution: --- → INCOMPLETE
You need to log in before you can comment on or make changes to this bug.