mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-11 01:45:33 +00:00
sys/: Some more cleanups, leaks fixed and checks.
Original commit message from CVS: 2004-11-08 Julien MOUTTE <julien@moutte.net> * sys/ximage/ximagesink.c: (gst_ximagesink_xcontext_clear), (gst_ximagesink_finalize): * sys/xvimage/xvimagesink.c: (gst_xvimagesink_xcontext_clear), (gst_xvimagesink_finalize): Some more cleanups, leaks fixed and checks.
This commit is contained in:
parent
4778549c39
commit
f69a495685
3 changed files with 34 additions and 5 deletions
|
@ -1,3 +1,10 @@
|
|||
2004-11-08 Julien MOUTTE <julien@moutte.net>
|
||||
|
||||
* sys/ximage/ximagesink.c: (gst_ximagesink_xcontext_clear),
|
||||
(gst_ximagesink_finalize):
|
||||
* sys/xvimage/xvimagesink.c: (gst_xvimagesink_xcontext_clear),
|
||||
(gst_xvimagesink_finalize): Some more cleanups, leaks fixed and checks.
|
||||
|
||||
2004-11-08 Wim Taymans <wim@fluendo.com>
|
||||
|
||||
* gst/typefind/gsttypefindfunctions.c: (aac_type_find):
|
||||
|
|
|
@ -856,6 +856,7 @@ static void
|
|||
gst_ximagesink_xcontext_clear (GstXImageSink * ximagesink)
|
||||
{
|
||||
g_return_if_fail (GST_IS_XIMAGESINK (ximagesink));
|
||||
g_return_if_fail (ximagesink->xcontext != NULL);
|
||||
|
||||
gst_caps_free (ximagesink->xcontext->caps);
|
||||
g_free (ximagesink->xcontext->par);
|
||||
|
@ -868,6 +869,7 @@ gst_ximagesink_xcontext_clear (GstXImageSink * ximagesink)
|
|||
|
||||
g_mutex_unlock (ximagesink->x_lock);
|
||||
|
||||
g_free (ximagesink->xcontext);
|
||||
ximagesink->xcontext = NULL;
|
||||
}
|
||||
|
||||
|
@ -1506,8 +1508,18 @@ gst_ximagesink_finalize (GObject * object)
|
|||
ximagesink->display_name = NULL;
|
||||
}
|
||||
|
||||
g_mutex_free (ximagesink->x_lock);
|
||||
g_mutex_free (ximagesink->pool_lock);
|
||||
if (ximagesink->par) {
|
||||
g_free (ximagesink->par);
|
||||
ximagesink->par = NULL;
|
||||
}
|
||||
if (ximagesink->x_lock) {
|
||||
g_mutex_free (ximagesink->x_lock);
|
||||
ximagesink->x_lock = NULL;
|
||||
}
|
||||
if (ximagesink->pool_lock) {
|
||||
g_mutex_free (ximagesink->pool_lock);
|
||||
ximagesink->pool_lock = NULL;
|
||||
}
|
||||
|
||||
G_OBJECT_CLASS (parent_class)->finalize (object);
|
||||
}
|
||||
|
|
|
@ -1054,6 +1054,7 @@ gst_xvimagesink_xcontext_clear (GstXvImageSink * xvimagesink)
|
|||
GList *formats_list, *channels_list;
|
||||
|
||||
g_return_if_fail (GST_IS_XVIMAGESINK (xvimagesink));
|
||||
g_return_if_fail (xvimagesink->xcontext != NULL);
|
||||
|
||||
formats_list = xvimagesink->xcontext->formats_list;
|
||||
|
||||
|
@ -1890,9 +1891,18 @@ gst_xvimagesink_finalize (GObject * object)
|
|||
xvimagesink->display_name = NULL;
|
||||
}
|
||||
|
||||
g_free (xvimagesink->par);
|
||||
g_mutex_free (xvimagesink->x_lock);
|
||||
g_mutex_free (xvimagesink->pool_lock);
|
||||
if (xvimagesink->par) {
|
||||
g_free (xvimagesink->par);
|
||||
xvimagesink->par = NULL;
|
||||
}
|
||||
if (xvimagesink->x_lock) {
|
||||
g_mutex_free (xvimagesink->x_lock);
|
||||
xvimagesink->x_lock = NULL;
|
||||
}
|
||||
if (xvimagesink->pool_lock) {
|
||||
g_mutex_free (xvimagesink->pool_lock);
|
||||
xvimagesink->pool_lock = NULL;
|
||||
}
|
||||
|
||||
G_OBJECT_CLASS (parent_class)->finalize (object);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue