Commit a3c47a07 authored by Guillaume Desmottes's avatar Guillaume Desmottes Committed by Tim-Philipp Müller

tools: fix device leaks in gst-device-monitor

gst_message_parse_device_{added,removed} is actually returning a new ref
on the device.

https://bugzilla.gnome.org/show_bug.cgi?id=768776
parent 54e4551c
......@@ -128,10 +128,12 @@ bus_msg_handler (GstBus * bus, GstMessage * msg, gpointer user_data)
case GST_MESSAGE_DEVICE_ADDED:
gst_message_parse_device_added (msg, &device);
device_added (device);
gst_object_unref (device);
break;
case GST_MESSAGE_DEVICE_REMOVED:
gst_message_parse_device_removed (msg, &device);
device_removed (device);
gst_object_unref (device);
break;
default:
g_print ("%s message\n", GST_MESSAGE_TYPE_NAME (msg));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment