Closed Bug 370702 Opened 17 years ago Closed 17 years ago

Fix refcount logging in cycle collecting auto refcount class

Categories

(Core :: XPCOM, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: graydon, Assigned: graydon)

Details

Attachments

(2 files)

The macros were set up wrong, producing some unusual leak reports. Fix them.
Actually I lied; the macros were fine as-is, we just need to return an appropriate refcount from incr operations, when in the stabilized-for-deletion state.
Attachment #255420 - Flags: review?(dbaron)
Can this be marked fixed now?
Yes.
Status: NEW → RESOLVED
Closed: 17 years ago
Resolution: --- → FIXED
Actually not.  I've still been seeing wacky nsTraceRefcnt output.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Attached patch patch 2Splinter Review
This makes the previous patch actually take effect -- we were ignoring the return values of incr and decr, but shouldn't be.  (This makes the Addref and Release methods look a little bit more like the threadsafe versions, for what it's worth.)
Attachment #257099 - Flags: review?(graydon)
Comment on attachment 257099 [details] [diff] [review]
patch 2

This fixes the nsTraceRefcnt output for me. Before it was reporting objects as leaking, even though they had balanced refcount trees.
Attachment #257099 - Flags: superreview+
Attachment #257099 - Flags: review?(graydon) → review+
Second fix checked in to trunk.
Status: REOPENED → RESOLVED
Closed: 17 years ago17 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: