Fixed minor leak in examples/util

Fixed minor pipeline/element memory leak in examples/util
This commit is contained in:
rob-deutsch
2019-02-10 18:07:09 +11:00
committed by Rob Deutsch
parent 434af9e0e8
commit 72c51607d7
2 changed files with 2 additions and 0 deletions

View File

@@ -76,6 +76,7 @@ void gstreamer_send_start_pipeline(GstElement *pipeline, int pipelineId) {
GstElement *appsink = gst_bin_get_by_name(GST_BIN(pipeline), "appsink");
g_object_set(appsink, "emit-signals", TRUE, NULL);
g_signal_connect(appsink, "new-sample", G_CALLBACK(gstreamer_send_new_sample_handler), s);
gst_object_unref(appsink);
gst_element_set_state(pipeline, GST_STATE_PLAYING);
}