From 314208fd25cbb3f9705d4c2340118b3d57354c61 Mon Sep 17 00:00:00 2001 From: Juro Bystricky Date: Tue, 9 Jul 2019 07:30:00 -0700 Subject: shell/report.c: fix "return with no value" MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fix the warning: report.c: In function ‘make_icon_css’: shell/report.c:103:9: warning: ‘return’ with no value, in function returning non-void [-Wreturn-type] Failure of the sanity test at the beginning of "make_icon_css" will result in returning of a random value instead of a gchar*. With this patch we return a gchar* to an empty string instead. Signed-off-by: Juro Bystricky --- shell/report.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'shell') diff --git a/shell/report.c b/shell/report.c index 89fcc4a3..4949c557 100644 --- a/shell/report.c +++ b/shell/report.c @@ -100,7 +100,7 @@ gchar *icon_name_css_id(const gchar *file) { gchar *make_icon_css(const gchar *file) { if (!file || *file == 0) - return; + return g_strdup(""); gchar *ret = NULL; gchar *path = g_build_filename(params.path_data, "pixmaps", file, NULL); gchar *contents = NULL; -- cgit v1.2.3