2009-01-11 [colin] 3.7.0cvs30
[claws.git] / src / folder.c
index fe8a65dcea46fbc8a413f57a867667b78febee93..2a7c9320d047efac446787df26f10b904fac2e90 100644 (file)
@@ -1324,14 +1324,10 @@ FolderItem *folder_find_child_item_by_name(FolderItem *item, const gchar *name)
        FolderItem *child;
 
        for (node = item->node->children; node != NULL; node = node->next) {
-               gchar *base;
                child = FOLDER_ITEM(node->data);
-               base = g_path_get_basename(child->path);
-               if (strcmp2(base, name) == 0) {
-                       g_free(base);
+               if (strcmp2(child->name, name) == 0) {
                        return child;
                }
-               g_free(base);
        }
 
        return NULL;