info: Don't leak log function user_data if the debug system is compiled out
authorSebastian Dröge <sebastian@centricular.com>
Sun, 31 Jan 2021 10:12:09 +0000 (12:12 +0200)
committerSebastian Dröge <sebastian@centricular.com>
Sun, 31 Jan 2021 10:12:09 +0000 (12:12 +0200)
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/742>

gst/gstinfo.c

index e363809330808c3235531811b9e48d494f9d15a7..6bdfb76e05ecf28f1ec905a4b380b02ae99487ed 100644 (file)
@@ -2338,6 +2338,8 @@ void
 gst_debug_add_log_function (GstLogFunction func, gpointer user_data,
     GDestroyNotify notify)
 {
+  if (notify)
+    notify (user_data);
 }
 
 guint