mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-18 22:36:33 +00:00
oggmux: Remove bus GSource to prevent a valgrind warning
This commit is contained in:
parent
5d38f0d398
commit
37b3878047
1 changed files with 3 additions and 1 deletions
|
@ -258,6 +258,7 @@ test_pipeline (const char *pipeline)
|
||||||
GError *error = NULL;
|
GError *error = NULL;
|
||||||
GMainLoop *loop;
|
GMainLoop *loop;
|
||||||
GstPadLinkReturn linkret;
|
GstPadLinkReturn linkret;
|
||||||
|
guint bus_watch = 0;
|
||||||
|
|
||||||
bin = gst_parse_launch (pipeline, &error);
|
bin = gst_parse_launch (pipeline, &error);
|
||||||
fail_unless (bin != NULL, "Error parsing pipeline: %s",
|
fail_unless (bin != NULL, "Error parsing pipeline: %s",
|
||||||
|
@ -280,7 +281,7 @@ test_pipeline (const char *pipeline)
|
||||||
/* run until we receive EOS */
|
/* run until we receive EOS */
|
||||||
loop = g_main_loop_new (NULL, FALSE);
|
loop = g_main_loop_new (NULL, FALSE);
|
||||||
bus = gst_element_get_bus (bin);
|
bus = gst_element_get_bus (bin);
|
||||||
gst_bus_add_watch (bus, (GstBusFunc) eos_watch, loop);
|
bus_watch = gst_bus_add_watch (bus, (GstBusFunc) eos_watch, loop);
|
||||||
gst_object_unref (bus);
|
gst_object_unref (bus);
|
||||||
|
|
||||||
start_pipeline (bin, pad);
|
start_pipeline (bin, pad);
|
||||||
|
@ -305,6 +306,7 @@ test_pipeline (const char *pipeline)
|
||||||
|
|
||||||
/* clean up */
|
/* clean up */
|
||||||
g_main_loop_unref (loop);
|
g_main_loop_unref (loop);
|
||||||
|
g_source_remove (bus_watch);
|
||||||
gst_object_unref (pad);
|
gst_object_unref (pad);
|
||||||
gst_object_unref (bin);
|
gst_object_unref (bin);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue