[vlc-devel] 1.0.0 OSX object leaks
Derk-Jan Hartman
hartman at videolan.org
Fri Apr 3 01:58:43 CEST 2009
On 3 apr 2009, at 01:42, Derk-Jan Hartman wrote:
> I'm not sure how many people are aware, but there is a large amount
> of object leaks in the OSX gui. I was looking at the generated
> leaklist today, and suddenly realized that there was a pattern. The
> pattern is that these are all objects used by setupVarMenuItem. I
> tested by inserting an immediate return in this function, and I can
> confirm that this seems to avoid the object leaks.
More specific. Autogenerated menu's have:
[o_mi setRepresentedObject: [NSValue valueWithPointer:[o_data retain]]];
But that object is never destroyed and thus the dealloc of
VLCAutoGeneratedMenuContent is never called and thus
vlc_object_release is not called.
That's a big oops we have there. We need to check for any existing
representedObject's and release them. Sounds like a nice little task
for tomorrow.
DJ
More information about the vlc-devel
mailing list