<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Jan 20, 2017 at 10:59 PM, Brendan Shanks <span dir="ltr"><<a href="mailto:brendan.shanks@teradek.com" target="_blank">brendan.shanks@teradek.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div>Hi, I'm writing an element that subclasses GstBin, and returns request ghost pads targeting elements inside the bin.<br></div><div>I noticed that GstGhostPads and GstProxyPads are leaking if they're present in the element when it gets disposed/finalized.<br></div><div><br></div><div>I'm unsure of the cause, but one thing I noticed is that the docs for gst_element_release_request_<wbr>pad() say that the call needs to be followed by gst_object_unref().<br></div></div>But in gst_element_dispose(), the element's release_pad() is being called without gst_object_unref() afterwards.<br><br>Is this an oversight, or is the pad getting an unnecessary ref somewhere else?<br></div></div></blockquote><div><br></div><div>I'd say the second option. If you share the relevants parts of your code we might help tracking it down.<br><br></div><div>The element's release_pad() has different requirements than that of gst_element_release_request_pad(). Usually the element's release_pad will call gst_element_remove_pad() that unparents the pad, removing the parent's reference to it.<br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><br></div><div>Thanks,<br></div>Brendan<br></div>
<br>______________________________<wbr>_________________<br>
gstreamer-devel mailing list<br>
<a href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.<wbr>freedesktop.org</a><br>
<a href="https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" rel="noreferrer" target="_blank">https://lists.freedesktop.org/<wbr>mailman/listinfo/gstreamer-<wbr>devel</a><br>
<br></blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature" data-smartmail="gmail_signature">Thiago Sousa Santos</div>
</div></div>