Disable callbacks after generating fingerprint.

This commit is contained in:
John Maguire 2012-01-06 16:45:34 +00:00
parent 598948d16e
commit 9bb37fda62
1 changed files with 2 additions and 0 deletions

View File

@ -143,6 +143,8 @@ QString Chromaprinter::CreateFingerprint() {
qLog(Debug) << "Decode time:" << decode_time << "Codegen time:" << codegen_time;
// Cleanup
callbacks.new_buffer = NULL;
gst_app_sink_set_callbacks(reinterpret_cast<GstAppSink*>(sink), &callbacks, this, NULL);
gst_bus_set_sync_handler(gst_pipeline_get_bus(GST_PIPELINE(pipeline_)), NULL, NULL);
g_source_remove(bus_callback_id);
gst_object_unref(pipeline_);