Closed
Bug 1187447
Opened 10 years ago
Closed 10 years ago
ProxyAccessible has non-virtual dtor
Categories
(Core :: Disability Access APIs, defect)
Core
Disability Access APIs
Tracking
()
RESOLVED
WONTFIX
People
(Reporter: erahm, Unassigned)
References
(Blocks 1 open bug)
Details
(Keywords: coverity, Whiteboard: [MemShrink][CID 1306763])
Coverity indicates parent class |ProxyAccessible| has a non-virtual dtor [1] and child class |DocAccessibleParent| has a non-trivial destructor [2].
It's possible for this to lead to a leak if an instance of |DocAccessibleParent| is referenced by it's parent class type and then deleted. It looks like this is possible in |ProxyEntry| [3].
[1] https://hg.mozilla.org/mozilla-central/annotate/2ddec2dedced/accessible/ipc/ProxyAccessible.h#l37
[2] https://hg.mozilla.org/mozilla-central/annotate/2ddec2dedced/accessible/ipc/DocAccessibleParent.h#l32
[3] https://hg.mozilla.org/mozilla-central/annotate/2ddec2dedced/accessible/ipc/DocAccessibleParent.h#l147
Comment 1•10 years ago
|
||
(In reply to Eric Rahm [:erahm] from comment #0)
> Coverity indicates parent class |ProxyAccessible| has a non-virtual dtor [1]
> and child class |DocAccessibleParent| has a non-trivial destructor [2].
>
> It's possible for this to lead to a leak if an instance of
> |DocAccessibleParent| is referenced by it's parent class type and then
> deleted. It looks like this is possible in |ProxyEntry| [3].
The hash table ProxyEntry is used for should never contain a pointer to a DocAccessibleParent* so that should never happen.Deleting a DocAccessibleparent anywhere other than TabChild::DeallocPDocAccessibleParent would be a bug forthat matter.
Reporter | ||
Comment 2•10 years ago
|
||
(In reply to Trevor Saunders (:tbsaunde) from comment #1)
> The hash table ProxyEntry is used for should never contain a pointer to a
> DocAccessibleParent* so that should never happen.Deleting a
> DocAccessibleparent anywhere other than
> TabChild::DeallocPDocAccessibleParent would be a bug forthat matter.
If you're sure it's not possible (nor could be possible in the future I guess) I'm fine w/ closing this as WONT FIX and I can tell coverity to ignore it.
Version: 33 Branch → Trunk
Comment 3•10 years ago
|
||
(In reply to Eric Rahm [:erahm] (out until 8/3) from comment #2)
> (In reply to Trevor Saunders (:tbsaunde) from comment #1)
> > The hash table ProxyEntry is used for should never contain a pointer to a
> > DocAccessibleParent* so that should never happen.Deleting a
> > DocAccessibleparent anywhere other than
> > TabChild::DeallocPDocAccessibleParent would be a bug forthat matter.
>
> If you're sure it's not possible (nor could be possible in the future I
> guess) I'm fine w/ closing this as WONT FIX and I can tell coverity to
> ignore it.
yeah, they pretty different to the point I'm tempted to get rid of the inheritance. So wontfix seems reasonable.
Reporter | ||
Comment 4•10 years ago
|
||
(In reply to Trevor Saunders (:tbsaunde) from comment #3)
> yeah, they pretty different to the point I'm tempted to get rid of the
> inheritance. So wontfix seems reasonable.
Alright, lets close this as wontfix then. I'll update coverity to ignore this class.
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → WONTFIX
Updated•7 years ago
|
Blocks: coverity-analysis
You need to log in
before you can comment on or make changes to this bug.
Description
•