diff options
author | Petri Latvala <petri.latvala@intel.com> | 2019-01-16 13:20:48 +0200 |
---|---|---|
committer | Petri Latvala <petri.latvala@intel.com> | 2019-01-28 15:40:28 +0200 |
commit | 4fcf5563154ddf89c5b4858e6da1a348eda6bdcc (patch) | |
tree | 8df42cb319ca02a9d126a3f4244bd5441d0ecfe5 /lib/igt_kmod.c | |
parent | c84502b6845153e6b7a391d5b5acc87592db8ecf (diff) |
lib/igt_kms: Aid static analyzer with the control flow
If we first find n amount of ':' in a string, the amount is still n
when we walk through it the second time.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Diffstat (limited to 'lib/igt_kmod.c')
-rw-r--r-- | lib/igt_kmod.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/igt_kmod.c b/lib/igt_kmod.c index 22c26021..91662eb3 100644 --- a/lib/igt_kmod.c +++ b/lib/igt_kmod.c @@ -86,6 +86,7 @@ static struct kmod_ctx *kmod_ctx(void) p = config_paths_str; for (i = 0; i < count; ++i) { + igt_assert(p != NULL); config_paths[i] = p; if ((p = strchr(p, ':'))) |