[Bug 768100] ghostpad: invalid ref getting internal pad

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Tue Jun 28 15:50:11 UTC 2016


https://bugzilla.gnome.org/show_bug.cgi?id=768100

--- Comment #7 from Miguel París Díaz <mparisdiaz at gmail.com> ---
Review of attachment 330439:
 --> (https://bugzilla.gnome.org/review?bug=768100&attachment=330439)

::: gst/gstghostpad.c
@@ +590,3 @@
     goto parent_failed;

+  GST_OBJECT_LOCK (internal);

gst_ghost_pad_construct is public, so it is not ensured to be only used from
gst_ghost_pad_new_full.
Moreover:
 -  I prefer having the discipline of managing GST_PROXY_PAD_INTERNAL into the
critical section
 - The lock is also held for the pad var

@@ +842,3 @@
   internal = GST_PROXY_PAD_INTERNAL (gpad);

+  if (newtarget == internal) {

I cannot use g_return_val_if_fail because this check is into the critical
section and the lock must be released.
Do you want to use g_warning with a specific message?

-- 
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