From e4e76688ca09448adaa152e0a757e4f0ee14cf52 Mon Sep 17 00:00:00 2001 From: lukefromdc Date: Thu, 28 Dec 2017 20:22:18 -0500 Subject: status-notifier: properly handle the NULL case for items patch by https://github.com/supermaz --- applets/notification_area/status-notifier/sn-host-v0.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/applets/notification_area/status-notifier/sn-host-v0.c b/applets/notification_area/status-notifier/sn-host-v0.c index 9915b1e3..afdc75e8 100644 --- a/applets/notification_area/status-notifier/sn-host-v0.c +++ b/applets/notification_area/status-notifier/sn-host-v0.c @@ -223,8 +223,10 @@ register_host_cb (GObject *source_object, items = sn_watcher_v0_gen_dup_registered_items (v0->watcher); - for (i = 0; items[i] != NULL; i++) - add_registered_item (v0, items[i]); + if (items) { + for (i = 0; items[i] != NULL; i++) + add_registered_item (v0, items[i]); + } g_strfreev (items); } -- cgit v1.2.1