gvfs r1094 - in trunk: . programs



Author: alexl
Date: Fri Jan 11 09:29:17 2008
New Revision: 1094
URL: http://svn.gnome.org/viewvc/gvfs?rev=1094&view=rev

Log:
2008-01-11  Alexander Larsson  <alexl redhat com>

	* programs/gvfs-mount.c (list_volumes):
	Fix crash if no mount in volume.



Modified:
   trunk/ChangeLog
   trunk/programs/gvfs-mount.c

Modified: trunk/programs/gvfs-mount.c
==============================================================================
--- trunk/programs/gvfs-mount.c	(original)
+++ trunk/programs/gvfs-mount.c	Fri Jan 11 09:29:17 2008
@@ -326,10 +326,13 @@
 	}
       
       mount = g_volume_get_mount (volume);
-      mounts = g_list_prepend (NULL, mount);
-      list_mounts (mounts, indent + 2, FALSE);
-      g_object_unref (mount);
-      g_list_free (mounts);
+      if (mount)
+	{
+	  mounts = g_list_prepend (NULL, mount);
+	  list_mounts (mounts, indent + 2, FALSE);
+	  g_list_free (mounts);
+	  g_object_unref (mount);
+	}
     }  
 }
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]