Closed Bug 52392 Opened 24 years ago Closed 24 years ago

nsXBLService is leaked

Categories

(Core :: Layout, defect, P3)

All
Mac System 8.5
defect

Tracking

()

VERIFIED FIXED
Future

People

(Reporter: sfraser_bugs, Assigned: hyatt)

Details

(Keywords: memory-footprint, memory-leak)

The nsXBLService never gets deleted on shutdown. One ref is being held by 
nsMemoryImpl, which AddRefs its memory pressure observers (warren needs to fix 
this), but there is at least one other ref that never goes away.
I filed bug 52393 on the nsMemory pressure addreffing.
This bug should probably be mine. I should rework nsMemoryImpl to use 
nsIObserver instead of its own proprietary scheme.
Assignee: hyatt → warren
Keywords: footprint, nsbeta3
Whiteboard: [nsbeta3+]
Sorry, I didn't notice your comment that you had filed a separate bug on 
nsMemoryImpl. I'll give this one back -- but to Brendan since it was his code, 
not Hyatt's.
Assignee: warren → brendan
Keywords: nsbeta3
Whiteboard: [nsbeta3+]
I didn't add that extra ref, whereever it is (I assure you, warren!), although I 
did initially neglect to remove the observer (since fixed).

sfraser, did you run the balancer?  In any case I'll help hyatt fix this.

/be
Status: NEW → ASSIGNED
Brendan: I
a) noted that memory pressure observers _were_ addreffed by the memory service,
   and that you were unregistering in the dtor (which would therefore never
   get called). This aspect is now fixed.
b) In the debugger, set a breakpoint in the nsXBLService dtor, omitted the call
   to register the memory pressure observer, and still didn't hit the dtor. So
   I assume that there is an outstanding extra addref.
Simon, thanks -- I grokked (a), which obviously wasn't an XBL bug; and (b) is 
something I think pre-dates my messing with XBL.  I'm not ducking this bug, 
especially if hyatt is too busy for it.  But I could use a clue on where this 
stuck ref is coming from, and I won't get to it right away cuz of mozilla.org 
business.  hyatt, any thoughts?

/be
I lied, punting to hyatt for now -- I'm jammed with mozilla.org stuff.  Let me
know if I can help, or take it back for later disposition.

/be
Assignee: brendan → hyatt
Status: ASSIGNED → NEW
->future
Target Milestone: --- → Future
I don't see this leaked any more in the logs.
Status: NEW → RESOLVED
Closed: 24 years ago
Resolution: --- → FIXED
Marking verified per last comments.
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.