]> spindle.queued.net Git - midori/commitdiff
Always insert completion addresses with a trailing slash
authorDale Whittaker <dayul@users.sf.net>
Sun, 1 Feb 2009 18:38:17 +0000 (19:38 +0100)
committerChristian Dywan <christian@twotoasts.de>
Sun, 1 Feb 2009 18:38:17 +0000 (19:38 +0100)
midori/midori-locationaction.c

index bdcfce06cb4ea72c1b874306152d51175d6d87a9..ea95cfdd7854a154fa22aeb91cbb4ff802f05015 100644 (file)
@@ -642,7 +642,11 @@ midori_location_action_iter_insert (MidoriLocationAction* location_action,
         model = location_action->model;
         gtk_list_store_insert (GTK_LIST_STORE (model), iter, position);
         path = gtk_tree_model_get_string_from_iter (model,  iter);
-        g_hash_table_insert (location_action->items, g_strdup (uri), path);
+        g_hash_table_insert (location_action->items,
+                             g_str_has_suffix (uri, "/") ?
+                             g_strdup (uri) :
+                             g_strconcat (uri, "/", NULL),
+                             path);
 
         return FALSE;
     }