From 2ea689c2997b084420f14f334ac350769494e2c7 Mon Sep 17 00:00:00 2001 From: Christian Hergert Date: Mon, 25 Nov 2024 16:43:33 -0800 Subject: [PATCH] sysprof/series: guard against invalid item --- src/sysprof/sysprof-series.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/sysprof/sysprof-series.c b/src/sysprof/sysprof-series.c index ec2b7381..137feac7 100644 --- a/src/sysprof/sysprof-series.c +++ b/src/sysprof/sysprof-series.c @@ -58,6 +58,9 @@ sysprof_series_get_item (GListModel *model, item = g_list_model_get_item (self->model, position); + if (item == NULL) + return NULL; + if (SYSPROF_SERIES_GET_CLASS (self)->get_series_item == NULL) return item;