Closed Bug 341686 Opened 20 years ago Closed 14 years ago

imgCache::Init's use of observers is slightly wrong

Categories

(Core :: Graphics: ImageLib, defect)

1.8 Branch
defect
Not set
minor

Tracking

()

RESOLVED INVALID

People

(Reporter: ispiked, Unassigned)

Details

From IRC: 18:04 <@dbaron> ispiked, it seems like the image cache should probably be owned by whoever's really responsible for owning it; having those observers registered isn't critical to its operation See also bug 338003 comment 3.
imgCache is an xpcom service and should really be inited as such. It is also a static class, but the way the observers are hooked up is wrong.
Some more comments: * Init leaks a 'imgCache' object (one is created for the observers but never freed) * The observers are never removed when the imgCache is shutdown * ClearCache(bool) is nowhere used except within imgCache itself, so can be removed from IDL? * Within the Observer, gChromeSession->EvictEntries() can be called directly * So all three ClearCache variant can then be removed
Assignee: pavlov → nobody
QA Contact: imagelib
The imgCache class no longer exists.
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.