After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 561281 - Incomplete disposal of Banshee.GStreamer.PlayerEngine
Incomplete disposal of Banshee.GStreamer.PlayerEngine
Status: RESOLVED FIXED
Product: banshee
Classification: Other
Component: GStreamer
git master
Other All
: Normal normal
: 1.x
Assigned To: Banshee Maintainers
Banshee Maintainers
Depends on:
Blocks: 555834
 
 
Reported: 2008-11-17 22:37 UTC by Chris Howie
Modified: 2009-04-28 17:57 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Fix (1.01 KB, patch)
2008-11-17 22:39 UTC, Chris Howie
committed Details | Review

Description Chris Howie 2008-11-17 22:37:46 UTC
Please describe the problem:
During disposal of Banshee.GStreamer.PlayerEngine, the class does not set its handle to reference a null IntPtr.  This causes later calls to unmanaged code to use a freed pointer, which may occur if the PlayerEngine class is used by an extension that is unloaded after the PlayerEngine is disposed.

Steps to reproduce:
The reproduction of this problem ties closely into how the visualization pipeline is managed, and no simple case is available.  See bug #555834 for an example of how this could be a problem.

Actual results:


Expected results:


Does this happen every time?


Other information:
Comment 1 Chris Howie 2008-11-17 22:39:06 UTC
Created attachment 122884 [details] [review]
Fix

Sets the handle to reference a null IntPtr after disposal.
Comment 2 Chris Howie 2008-11-17 22:40:39 UTC
Also, am I the only one who doesn't think this is the appropriate place to be using a HandleRef?  Perhaps a SafeHandle, but HandleRef is doing exactly nothing in this context.
Comment 3 Bertrand Lorentz 2008-11-17 23:00:27 UTC
I don't know about handles and stuff, but the patch fixes my crash on exit with the visualization extension.
Comment 4 Bertrand Lorentz 2009-04-28 17:57:07 UTC
The fix was committed to the stable-vis branch, as part of the patch in bug #555834.