[Bug 728490] v4l2src: Missing unref in decide_allocation

GStreamer (bugzilla.gnome.org) bugzilla at gnome.org
Fri Apr 18 08:18:30 PDT 2014


https://bugzilla.gnome.org/show_bug.cgi?id=728490
  GStreamer | gst-plugins-good | 1.2.3

--- Comment #4 from Aurélien Zanelli <aurelien.zanelli at parrot.com> 2014-04-18 15:18:25 UTC ---
(In reply to comment #2)
> Ok, gst_query_set_nth_allocation_pool() and gst_query_add_allocation_pool()
> will ref the given pool, so the pool is transferred none.
> 
> gst_query_parse_nth_allocation_pool() give you a ref on the pool. This mean
> that if you didn't switch the pool to our own pool, you would be leaking a
> downstream pool. Here's what I propose to fix this correctly:
> 
> after set_nth.. and add_allo, unref the pool. When replacing the pool, unref
> the pool from the allocation, and ref our own pool. This should be clean.

You are right, in the case we didn't switch the pool to our own pool, we will
be leaking a ref. This case still happen on master so I will also do a patch
for master branch.

-- 
Configure bugmail: https://bugzilla.gnome.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.


More information about the gstreamer-bugs mailing list