commit d52aded0fccbff2e4933c2efc3c4909f1590a4c8
parent 8cb4112c152c5e3b155fcfba18246febda805acb
Author: Jonathan Boeing <jonathan@claws-mail.org>
Date: Sat, 11 Sep 2021 19:08:56 -0700
Fix crash when unloading RSSyl plugin
Bug 4467
folder is not a LocalFolder, so calling folder_local_folder_destroy() passes
a bad address to g_free(). Causes a potential crash on Windows, and valgrind
logs an 'Invalid read of size 8' and 'Invalid free() / delete / delete[] /
realloc()'
Diffstat:
2 files changed, 0 insertions(+), 3 deletions(-)
diff --git a/src/plugins/rssyl/claws.def b/src/plugins/rssyl/claws.def
@@ -54,7 +54,6 @@ folder_item_search_msgs_local
folder_item_set_xml
folder_item_update_freeze
folder_item_update_thaw
-folder_local_folder_destroy
folder_local_name_ok
folder_new
folder_register_class
diff --git a/src/plugins/rssyl/rssyl.c b/src/plugins/rssyl/rssyl.c
@@ -32,7 +32,6 @@
/* Claws Mail includes */
#include <folder.h>
#include <procmsg.h>
-#include <localfolder.h>
#include <main.h>
#include <mh.h>
#include <xml.h>
@@ -259,7 +258,6 @@ static Folder *rssyl_new_folder(const gchar *name, const gchar *path)
static void rssyl_destroy_folder(Folder *folder)
{
- folder_local_folder_destroy(LOCAL_FOLDER(folder));
}
static void rssyl_item_set_xml(Folder *folder, FolderItem *item, XMLTag *tag)