libsysprof: check for enough symbols to dereference

This commit is contained in:
Christian Hergert
2019-05-28 20:14:57 -07:00
parent 7f92889076
commit 716b913347

View File

@ -222,7 +222,7 @@ _sysprof_kernel_symbols_lookup (const SysprofKernelSymbols *self,
g_assert (self != NULL);
if (self->len == 0)
if (self->len < 2)
return NULL;
/* Short circuit if this is out of range */