From 372202600b8e178ec4181bea7a5e8049ae5d9696 Mon Sep 17 00:00:00 2001 From: Pierre Pronchery Date: Sun, 2 Aug 2009 03:14:31 +0000 Subject: [PATCH] Checking and warning for errors while loading the menu entries --- src/panel.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/panel.c b/src/panel.c index 88b1944..1978b17 100644 --- a/src/panel.c +++ b/src/panel.c @@ -413,7 +413,11 @@ static gboolean _panel_idle_apps(gpointer data) continue; /* XXX report error */ else config_reset(config); - config_load(config, name); + if(config_load(config, name) != 0) + { + error_print("panel"); + continue; + } q = config_get(config, section, "Name"); r = config_get(config, section, "Exec"); if(q == NULL || r == NULL) @@ -424,6 +428,8 @@ static gboolean _panel_idle_apps(gpointer data) } free(name); closedir(dir); + if(config != NULL) + config_delete(config); return FALSE; }