mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-26 06:54:49 +00:00
wavenc: Remove bus GSource to prevent a valgrind warning
This commit is contained in:
parent
39bb942bb0
commit
84c3b06353
1 changed files with 5 additions and 1 deletions
|
@ -69,6 +69,7 @@ make_n_channel_wav (const gint channels, const GValueArray * arr)
|
||||||
GstBus *bus;
|
GstBus *bus;
|
||||||
GMainLoop *loop;
|
GMainLoop *loop;
|
||||||
guint i;
|
guint i;
|
||||||
|
guint bus_watch = 0;
|
||||||
|
|
||||||
audiotestsrc = g_new0 (GstElement *, channels);
|
audiotestsrc = g_new0 (GstElement *, channels);
|
||||||
|
|
||||||
|
@ -104,7 +105,7 @@ make_n_channel_wav (const gint channels, const GValueArray * arr)
|
||||||
|
|
||||||
bus = gst_element_get_bus (pipeline);
|
bus = gst_element_get_bus (pipeline);
|
||||||
fail_unless (bus != NULL);
|
fail_unless (bus != NULL);
|
||||||
gst_bus_add_watch (bus, bus_handler, loop);
|
bus_watch = gst_bus_add_watch (bus, bus_handler, loop);
|
||||||
gst_object_unref (bus);
|
gst_object_unref (bus);
|
||||||
|
|
||||||
gst_element_set_state (pipeline, GST_STATE_PLAYING);
|
gst_element_set_state (pipeline, GST_STATE_PLAYING);
|
||||||
|
@ -113,6 +114,9 @@ make_n_channel_wav (const gint channels, const GValueArray * arr)
|
||||||
|
|
||||||
gst_object_unref (pipeline);
|
gst_object_unref (pipeline);
|
||||||
g_free (audiotestsrc);
|
g_free (audiotestsrc);
|
||||||
|
|
||||||
|
g_main_loop_unref (loop);
|
||||||
|
g_source_remove (bus_watch);
|
||||||
}
|
}
|
||||||
|
|
||||||
GST_START_TEST (test_encode_stereo)
|
GST_START_TEST (test_encode_stereo)
|
||||||
|
|
Loading…
Reference in a new issue