Ignore an empty Path value
authorMatthias Clasen <matthiasc@src.gnome.org>
Mon, 15 Sep 2008 16:26:38 +0000 (16:26 +0000)
committerMatthias Clasen <matthiasc@src.gnome.org>
Mon, 15 Sep 2008 16:26:38 +0000 (16:26 +0000)
svn path=/trunk/; revision=7492

gio/ChangeLog
gio/gdesktopappinfo.c

index 7b519e7..b1fc1ec 100644 (file)
@@ -1,5 +1,13 @@
 2008-09-15  Matthias Clasen  <mclasen@redhat.com>
 
+       Bug 552352 – g_app_info_launch doesn't work if "Path" key in .desktop 
+       file is empty
+
+       * gdesktopappinfo.c (g_desktop_app_info_new_from_keyfile): Ignore
+       an empty Path value.  
+
+2008-09-15  Matthias Clasen  <mclasen@redhat.com>
+
        Bug 551681 – g_content_type_guess() too naive with filenames
 
        * gcontenttype.c (g_content_type_guess): Check whether there's a '/'
index af57e63..027334c 100644 (file)
@@ -272,6 +272,12 @@ g_desktop_app_info_new_from_keyfile (GKeyFile *key_file)
   if (info->exec)
     info->binary = binary_from_exec (info->exec);
   
+  if (info->path && info->path[0] == '\0')
+    {
+      g_free (info->path);
+      info->path = NULL:
+    }
+
   return info;
 }