diff options
author | Haihua Hu <jared.hu@nxp.com> | 2016-11-15 18:10:24 +0800 |
---|---|---|
committer | Matthew Waters <matthew@centricular.com> | 2016-11-15 21:22:52 +1100 |
commit | d0026b32e823014cb019ce0ab63b3b1d5b3dde10 (patch) | |
tree | 3021dc17fe9a94ed4410cbd42c37ad0aed3c5c48 | |
parent | b810d09fd6c98f8289dd5df2b213e77c8e0daf27 (diff) | |
download | gstreamer-plugins-bad-d0026b32e823014cb019ce0ab63b3b1d5b3dde10.tar.gz |
glwindow: use g_thread_unref() to release navigation thread
use g_thread_unref() to release navigation thread to avoid memory leak
https://bugzilla.gnome.org/show_bug.cgi?id=774462
-rw-r--r-- | gst-libs/gst/gl/gstglwindow.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/gst-libs/gst/gl/gstglwindow.c b/gst-libs/gst/gl/gstglwindow.c index 57b296efe..3ac2441e4 100644 --- a/gst-libs/gst/gl/gstglwindow.c +++ b/gst-libs/gst/gl/gstglwindow.c @@ -343,6 +343,8 @@ gst_gl_window_finalize (GObject * object) /* wait until navigation thread finished */ while (window->priv->nav_alive) g_cond_wait (&window->priv->nav_destroy_cond, &window->priv->nav_lock); + /* release the resources of navigation thread */ + g_thread_unref (window->priv->navigation_thread); window->priv->navigation_thread = NULL; } g_mutex_unlock (&window->priv->nav_lock); |