changeset 2195:0cdbe938b525 merge-requests/4

Be robust against desktop files without an Exec key.
author Gabriel <g2p.code@gmail.com>
date Thu, 27 Sep 2012 00:06:38 +0200
parents 9063024ebc5a
children
files src/editors.c
diffstat 1 files changed, 1 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/editors.c	Sun Sep 23 11:19:36 2012 +0200
+++ b/src/editors.c	Thu Sep 27 00:06:38 2012 +0200
@@ -292,6 +292,7 @@
 		}
 
 	editor->exec = g_key_file_get_string(key_file, DESKTOP_GROUP, "Exec", NULL);
+	if (!editor->exec) editor->exec = g_strdup("");
 
 	editor->menu_path = g_key_file_get_string(key_file, DESKTOP_GROUP, "X-Geeqie-Menu-Path", NULL);
 	if (!editor->menu_path) editor->menu_path = g_strdup("EditMenu/ExternalMenu");