Skip to content

Commit

Permalink
tools: fix device leaks in gst-device-monitor
Browse files Browse the repository at this point in the history
gst_message_parse_device_{added,removed} is actually returning a new ref
on the device.

https://bugzilla.gnome.org/show_bug.cgi?id=768776
  • Loading branch information
Guillaume Desmottes authored and tp-m committed Jul 15, 2016
1 parent 54e4551 commit a3c47a0
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tools/gst-device-monitor.c
Expand Up @@ -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));
Expand Down

0 comments on commit a3c47a0

Please sign in to comment.