diff options
author | Thibault Saunier <tsaunier@igalia.com> | 2021-01-05 10:06:40 -0300 |
---|---|---|
committer | Thibault Saunier <tsaunier@igalia.com> | 2021-01-05 11:33:51 -0300 |
commit | 73a674ac2d737a7a631914b48375681de884ecbc (patch) | |
tree | 6e1beb1e40ebb5bfb10ffd61fbd549b7119f70bb | |
parent | f47e5b163f6638c40559fbed2c43ecd401919135 (diff) |
validate: Do not check strv length on NULL pointers
This is not legal
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-devtools/-/merge_requests/234>
-rw-r--r-- | validate/gst/validate/gst-validate-scenario.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/validate/gst/validate/gst-validate-scenario.c b/validate/gst/validate/gst-validate-scenario.c index bc7586b..9e84c5d 100644 --- a/validate/gst/validate/gst-validate-scenario.c +++ b/validate/gst/validate/gst-validate-scenario.c @@ -4433,7 +4433,7 @@ gst_validate_scenario_get_include_paths (const gchar * relative_scenario) 0) : NULL; g_free (scenarios_path); - n = g_strv_length (env_scenariodir); + n = env_scenariodir ? g_strv_length (env_scenariodir) : 0; env_scenariodir = g_realloc_n (env_scenariodir, n + 3, sizeof (gchar *)); env_scenariodir[n] = g_build_filename (g_get_user_data_dir (), "gstreamer-" GST_API_VERSION, "validate", |