Remove password from passwordstore when deleting a RSSyl feed.
authorAndrej Kacian <ticho@claws-mail.org>
Sat, 9 Apr 2016 13:43:02 +0000 (15:43 +0200)
committerAndrej Kacian <ticho@claws-mail.org>
Sat, 9 Apr 2016 13:43:02 +0000 (15:43 +0200)
src/plugins/rssyl/rssyl.c
src/plugins/rssyl/rssyl_gtk.h

index 139f5af..806a83b 100644 (file)
@@ -624,6 +624,7 @@ static gint rssyl_rename_folder(Folder *folder, FolderItem *item,
 static gint rssyl_remove_folder(Folder *folder, FolderItem *item)
 {
        gchar *path = NULL;
+       RFolderItem *ritem = (RFolderItem *)item;
 
        g_return_val_if_fail(folder != NULL, -1);
        g_return_val_if_fail(item != NULL, -1);
@@ -638,8 +639,11 @@ static gint rssyl_remove_folder(Folder *folder, FolderItem *item)
                g_free(path);
                return -1;
        }
-
        g_free(path);
+
+       if (ritem->url != NULL)
+               rssyl_passwd_set(ritem, NULL);
+
        folder_item_remove(item);
 
        return 0;
index 6a97fc8..ba8ddb7 100644 (file)
@@ -10,8 +10,6 @@
 void rssyl_gtk_init(void);
 void rssyl_gtk_done(void);
 
-GtkWidget *rssyl_feed_removal_dialog(gchar *name, GtkWidget **rmcache_widget);
-
 void rssyl_gtk_prop(RFolderItem *ritem);
 
 #endif /* __RSSYL_GTK */