--- gftp-2.0.18/src/gtk/bookmarks.c~ 2005-01-04 14:32:20.000000000 +0100 +++ gftp-2.0.18/src/gtk/bookmarks.c 2006-07-22 19:37:41.000000000 +0200 @@ -683,7 +683,6 @@ oldpathlen = strlen (entry->path); if ((pos = strrchr (entry->path, '/')) != NULL) { - pos = entry->path; tempchar = *pos; *pos = '\0'; newpath = gftp_build_path (NULL, entry->path, tempstr, NULL); @@ -750,11 +749,14 @@ while (tempentry != NULL) { - g_hash_table_remove (new_bookmarks_htable, tempentry->path); - - bmentry = g_hash_table_lookup (gftp_bookmarks_htable, + bmentry = g_hash_table_lookup (gftp_bookmarks_htable, tempentry->path); - if (bmentry->oldpath == NULL) + if (bmentry == NULL) + bmentry = g_hash_table_lookup (new_bookmarks_htable, + tempentry->path); + + g_hash_table_remove (new_bookmarks_htable, tempentry->path); + if (bmentry->oldpath == NULL) bmentry->oldpath = tempentry->path; else g_free (tempentry->path);