mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-19 16:21:17 +00:00
dtlsconnection: Fix memory leak while setting closure
https://bugzilla.gnome.org/show_bug.cgi?id=749325
This commit is contained in:
parent
1f738ca5b8
commit
c44acd8bde
1 changed files with 4 additions and 0 deletions
|
@ -454,6 +454,10 @@ gst_dtls_connection_set_send_callback (GstDtlsConnection * self,
|
||||||
g_mutex_lock (&self->priv->mutex);
|
g_mutex_lock (&self->priv->mutex);
|
||||||
GST_TRACE_OBJECT (self, "locked @ set_send_callback");
|
GST_TRACE_OBJECT (self, "locked @ set_send_callback");
|
||||||
|
|
||||||
|
if (self->priv->send_closure) {
|
||||||
|
g_closure_unref (self->priv->send_closure);
|
||||||
|
self->priv->send_closure = NULL;
|
||||||
|
}
|
||||||
self->priv->send_closure = closure;
|
self->priv->send_closure = closure;
|
||||||
|
|
||||||
if (closure && G_CLOSURE_NEEDS_MARSHAL (closure)) {
|
if (closure && G_CLOSURE_NEEDS_MARSHAL (closure)) {
|
||||||
|
|
Loading…
Reference in a new issue