telepathy-mission-control: Default account backend: when deleting from the keyring, remove from secrets

Simon McVittie smcv at kemper.freedesktop.org
Thu Sep 6 10:18:04 PDT 2012


Module: telepathy-mission-control
Branch: master
Commit: bd56ee0e36a681ee50d3e02d4f158bbc5df462f1
URL:    http://cgit.freedesktop.org/telepathy/telepathy-mission-control/commit/?id=bd56ee0e36a681ee50d3e02d4f158bbc5df462f1

Author: Simon McVittie <simon.mcvittie at collabora.co.uk>
Date:   Thu Aug 30 18:12:06 2012 +0100

Default account backend: when deleting from the keyring, remove from secrets

Otherwise we'd just delete it, then (because it's still in secrets)
re-commit it!

Signed-off-by: Simon McVittie <simon.mcvittie at collabora.co.uk>
Reviewed-by: Jonny Lamb <jonny.lamb at collabora.co.uk>
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=42088
Cherry-picked-from: 16e4507c5001f6f45158ef3d0b46998fa8c1ca2a

---

 src/mcd-account-manager-default.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/src/mcd-account-manager-default.c b/src/mcd-account-manager-default.c
index 6989d62..22eb29e 100644
--- a/src/mcd-account-manager-default.c
+++ b/src/mcd-account-manager-default.c
@@ -78,11 +78,13 @@ _delete_from_keyring (const McpAccountStorage *self,
       /* flag the whole account as purged */
       gchar *removed = g_strdup (account);
       g_hash_table_replace (amd->removed_accounts, removed, removed);
+      g_key_file_remove_group (amd->secrets, removed, NULL);
     }
   else
     {
       /* remember to forget this one param */
       g_key_file_set_value (amd->removed, account, key, "");
+      g_key_file_remove_key (amd->secrets, account, key, NULL);
     }
 }
 



More information about the telepathy-commits mailing list