* src/filter.c
[claws.git] / src / mh.c
index 83075ed..2c4a765 100644 (file)
--- a/src/mh.c
+++ b/src/mh.c
@@ -126,10 +126,10 @@ void mh_folder_destroy(MHFolder *folder)
 
 static void mh_folder_init(Folder *folder, const gchar *name, const gchar *path)
 {
-       folder_local_folder_init(folder, name, path);
-
        folder->type = F_MH;
 
+       folder_local_folder_init(folder, name, path);
+
 /*
        folder->get_msg_list        = mh_get_msg_list;
 */
@@ -863,7 +863,7 @@ void mh_scan_tree(Folder *folder)
 
        g_return_if_fail(folder != NULL);
 
-       item = folder_item_new(folder->name, NULL);
+       item = folder_item_new(folder, folder->name, NULL);
        item->folder = folder;
        folder->node = g_node_new(item);
 
@@ -942,7 +942,7 @@ FolderItem *mh_create_folder(Folder *folder, FolderItem *parent,
                                   NULL);
        else
                path = g_strdup(name);
-       new_item = folder_item_new(name, path);
+       new_item = folder_item_new(folder, name, path);
        folder_item_append(parent, new_item);
        g_free(path);
 
@@ -1227,7 +1227,7 @@ static void mh_scan_tree_recursive(FolderItem *item)
                                continue;
                        }
 
-                       new_item = folder_item_new(d->d_name, entry);
+                       new_item = folder_item_new(item->folder, d->d_name, entry);
                        folder_item_append(item, new_item);
                        if (!item->path) {
                                if (!strcmp(d->d_name, INBOX_DIR)) {