[gvfs/gnome-2-28] Fix creating mount_spec from string



commit 5ae16ae1feb4e6076fce5794b04481c780f406f4
Author: Tomas Bzatek <tbzatek redhat com>
Date:   Thu Oct 8 15:48:15 2009 +0200

    Fix creating mount_spec from string
    
    Don't consume the ending character.

 common/gmountspec.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/common/gmountspec.c b/common/gmountspec.c
index c55f996..1a9a60a 100644
--- a/common/gmountspec.c
+++ b/common/gmountspec.c
@@ -514,7 +514,7 @@ g_mount_spec_new_from_string (const gchar     *str,
   if (colon)
     {
       item.key = g_strdup ("type");
-      item.value = g_strndup (str, colon - str - 1);
+      item.value = g_strndup (str, colon - str);
       g_array_append_val (items, item);
       str = colon + 1;
     }



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