scenario: Do not dereference NULL pointer

This commit is contained in:
Thibault Saunier 2019-07-08 23:36:52 -04:00
parent 8498861a28
commit aea1082116

View file

@ -2922,7 +2922,8 @@ gst_validate_action_default_prepare_func (GstValidateAction * action)
gst_validate_structure_resolve_variables (action->structure,
scenario->priv->vars);
for (i = 0; type->parameters[i].name; i++) {
if (g_str_has_suffix (type->parameters[i].types, "(GstClockTime)"))
if (type->parameters[i].types &&
g_str_has_suffix (type->parameters[i].types, "(GstClockTime)"))
gst_validate_action_get_clocktime (scenario, action,
type->parameters[i].name, &tmp);
}