mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 12:11:13 +00:00
jack: don't leak client name when freeing the element
And add gtk-doc chunks for the new property. https://bugzilla.gnome.org/show_bug.cgi?id=665872
This commit is contained in:
parent
92cfb335cd
commit
2e078fa556
2 changed files with 26 additions and 0 deletions
|
@ -717,6 +717,13 @@ gst_jack_audio_sink_class_init (GstJackAudioSinkClass * klass)
|
|||
"The Jack server to connect to (NULL = default)",
|
||||
DEFAULT_PROP_SERVER, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
|
||||
|
||||
/**
|
||||
* GstJackAudioSink:client-name
|
||||
*
|
||||
* The client name to use.
|
||||
*
|
||||
* Since: 0.10.31
|
||||
*/
|
||||
g_object_class_install_property (gobject_class, PROP_CLIENT_NAME,
|
||||
g_param_spec_string ("client-name", "Client name",
|
||||
"The client name of the Jack instance (NULL = default)",
|
||||
|
@ -760,6 +767,12 @@ gst_jack_audio_sink_dispose (GObject * object)
|
|||
GstJackAudioSink *sink = GST_JACK_AUDIO_SINK (object);
|
||||
|
||||
gst_caps_replace (&sink->caps, NULL);
|
||||
|
||||
if (sink->client_name != NULL) {
|
||||
g_free (sink->client_name);
|
||||
sink->client_name = NULL;
|
||||
}
|
||||
|
||||
G_OBJECT_CLASS (parent_class)->dispose (object);
|
||||
}
|
||||
|
||||
|
|
|
@ -737,6 +737,13 @@ gst_jack_audio_src_class_init (GstJackAudioSrcClass * klass)
|
|||
"The Jack server to connect to (NULL = default)",
|
||||
DEFAULT_PROP_SERVER, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
|
||||
|
||||
/**
|
||||
* GstJackAudioSrc:client-name
|
||||
*
|
||||
* The client name to use.
|
||||
*
|
||||
* Since: 0.10.31
|
||||
*/
|
||||
g_object_class_install_property (gobject_class, PROP_CLIENT_NAME,
|
||||
g_param_spec_string ("client-name", "Client name",
|
||||
"The client name of the Jack instance (NULL = default)",
|
||||
|
@ -784,6 +791,12 @@ gst_jack_audio_src_dispose (GObject * object)
|
|||
GstJackAudioSrc *src = GST_JACK_AUDIO_SRC (object);
|
||||
|
||||
gst_caps_replace (&src->caps, NULL);
|
||||
|
||||
if (src->client_name != NULL) {
|
||||
g_free (src->client_name);
|
||||
src->client_name = NULL;
|
||||
}
|
||||
|
||||
G_OBJECT_CLASS (parent_class)->dispose (object);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue