summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJordan Petridis <jpetridis@gnome.org>2020-06-11 20:57:58 +0300
committerGStreamer Merge Bot <gitlab-merge-bot@gstreamer-foundation.org>2020-09-25 04:15:34 +0000
commit1390b20c948bb582011ff7467fc8d8fb0c502da5 (patch)
tree2a6505c1c92d2000e87b1182b0a1bdb117cb3099
parent88dff5ddbb14beb3fb58c77fed46b5db95da05b5 (diff)
downloadgstreamer-plugins-base-1390b20c948bb582011ff7467fc8d8fb0c502da5.tar.gz
libvisual: use gst_element_class_set_metadata when passing dynamic strings
gst_element_class_set_metadata is meant to only be used with static or inlined strings, which isn't the case for this element resulting in use-after-free later on. https://gstreamer.freedesktop.org/documentation/gstreamer/gstelement.html?gi-language=c#gst_element_class_set_static_metadata Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/828>
-rw-r--r--ext/libvisual/visual.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/libvisual/visual.c b/ext/libvisual/visual.c
index 2ed94f0fc..47ce29bcb 100644
--- a/ext/libvisual/visual.c
+++ b/ext/libvisual/visual.c
@@ -106,7 +106,7 @@ gst_visual_class_init (gpointer g_class, gpointer class_data)
gst_element_class_add_static_pad_template (element_class, &src_template);
gst_element_class_add_static_pad_template (element_class, &sink_template);
- gst_element_class_set_static_metadata (element_class,
+ gst_element_class_set_metadata (element_class,
longname, "Visualization",
klass->plugin->info->about, "Benjamin Otte <otte@gnome.org>");