Closed
Bug 374155
Opened 19 years ago
Closed 18 years ago
Switch strong pointers to weak ones where it is safe to do so
Categories
(Core :: General, defect)
Core
General
Tracking
()
RESOLVED
WONTFIX
People
(Reporter: taras.mozilla, Assigned: taras.mozilla)
Details
Attachments
(2 files)
|
674 bytes,
patch
|
Details | Diff | Splinter Review | |
|
3.33 KB,
patch
|
Details | Diff | Splinter Review |
See Strong reference domination at http://wiki.mozilla.org/DeHydra for a sample problem.
Updated•19 years ago
|
OS: Linux → All
Product: Firefox → Core
QA Contact: general → general
Hardware: PC → All
| Assignee | ||
Comment 1•19 years ago
|
||
| Assignee | ||
Updated•19 years ago
|
Attachment #258741 -
Attachment description: simplest case → simplest case for nsPIDOMWindow.h
You haven't changed GetNotificationCallbacks or introduced a non-addrefing version, so this just leaks, right? GetNotificationCallbacks adds a ref and nothing releases it.
| Assignee | ||
Comment 3•19 years ago
|
||
(In reply to comment #2)
> You haven't changed GetNotificationCallbacks or introduced a non-addrefing
> version, so this just leaks, right? GetNotificationCallbacks adds a ref and
> nothing releases it.
>
Looks like I did not understand how you want to proceed with this. Initially I thought that this was rewritable at callsites, but that does not seem to be the case since the callee is doing AddRef. Or am I overlooking something?
It's certainly possible to examine all call sites in the mozilla src(minus the usual blindness caused by CPP) to build a list of getter functions to rewrite and then rewrite them(easy part). However this wont work for any functions that are visible to the outside world since we aren't in control of that code. Also not sure if that's worth the hassle to save 2 ref count operations.
Another approach is to identify these cases in hot paths and do most of the work by hand.
What's the correct way to approach this?
| Assignee | ||
Comment 4•18 years ago
|
||
We decided this wasn't viable. Closing old bug
Status: NEW → RESOLVED
Closed: 18 years ago
Resolution: --- → WONTFIX
You need to log in
before you can comment on or make changes to this bug.
Description
•