mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 04:01:08 +00:00
frei0r: Fix crashes if plugins don't provide correct property information
The vertigo plugin for example claims to have 3 properties but the 3rd property does nothing and has a NULL name. Fixes bug #630783. Thanks to Martti Kühne for debugging this.
This commit is contained in:
parent
d0d4055732
commit
498620d16c
1 changed files with 6 additions and 0 deletions
|
@ -72,6 +72,12 @@ gst_frei0r_klass_install_properties (GObjectClass * gobject_class,
|
|||
|
||||
ftable->get_param_info (param_info, i);
|
||||
|
||||
if (!param_info->name) {
|
||||
GST_ERROR ("Property %d of %s without a valid name", i,
|
||||
g_type_name (G_TYPE_FROM_CLASS (gobject_class)));
|
||||
continue;
|
||||
}
|
||||
|
||||
prop_name = g_ascii_strdown (param_info->name, -1);
|
||||
g_strcanon (prop_name, G_CSET_A_2_Z G_CSET_a_2_z G_CSET_DIGITS "-+", '-');
|
||||
/* satisfy glib2 (argname[0] must be [A-Za-z]) */
|
||||
|
|
Loading…
Reference in a new issue