Fix bug #3009 ‘"Rebuild folder tree" causes SIGSEGV if a directory name isn't valid...
authorRicardo Mones <ricardo@mones.org>
Thu, 5 Dec 2013 10:00:29 +0000 (11:00 +0100)
committerRicardo Mones <ricardo@mones.org>
Thu, 5 Dec 2013 10:00:29 +0000 (11:00 +0100)
Based on initial patch submitted by Fabian Keil <fk@fabiankeil.de>

src/folder.c

index 93d7479..b9a3dc3 100644 (file)
@@ -346,7 +346,7 @@ FolderItem *folder_item_new(Folder *folder, const gchar *name, const gchar *path
        cm_return_val_if_fail(item != NULL, NULL);
 
        item->stype = F_NORMAL;
-       item->name = g_strdup(name);
+       item->name = conv_filename_to_utf8(name);
        item->path = g_strdup(path);
        item->mtime = 0;
        item->new_msgs = 0;