aboutsummaryrefslogtreecommitdiffstats
path: root/storage.c
diff options
context:
space:
mode:
authorWilmer van der Gaast <wilmer@gaast.net>2013-04-20 14:05:55 +0100
committerWilmer van der Gaast <wilmer@gaast.net>2013-04-20 14:05:55 +0100
commite31e5b8f340a162180830dbe42dd438e59591cfd (patch)
tree029bbb166fda2e9b98a041039338835beb35a08e /storage.c
parent9b2a8c10b61540c3c6892a4de7f52bf8657d455e (diff)
parentbfafb99e6162b72e0f1ca7639de05f2b7bb3b23c (diff)
Merging "storage" branch which I wrote long ago. It separates generation of
XML-formatted user configs from disk I/O so we can try to start using other mechanisms to store them (a REST API or something, for example).
Diffstat (limited to 'storage.c')
-rw-r--r--storage.c43
1 files changed, 0 insertions, 43 deletions
diff --git a/storage.c b/storage.c
index d64d9cda..cb6814c4 100644
--- a/storage.c
+++ b/storage.c
@@ -194,46 +194,3 @@ storage_status_t storage_remove (const char *nick, const char *password)
return ret;
}
-
-#if 0
-Not using this yet. Test thoroughly before adding UI hooks to this function.
-
-storage_status_t storage_rename (const char *onick, const char *nnick, const char *password)
-{
- storage_status_t status;
- GList *gl = global.storage;
- storage_t *primary_storage = gl->data;
- irc_t *irc;
-
- /* First, try to rename in the current write backend, assuming onick
- * is stored there */
- status = primary_storage->rename(onick, nnick, password);
- if (status != STORAGE_NO_SUCH_USER)
- return status;
-
- /* Try to load from a migration backend and save to the current backend.
- * Explicitly remove the account from the migration backend as otherwise
- * it'd still be usable under the old name */
-
- irc = g_new0(irc_t, 1);
- status = storage_load(onick, password, irc);
- if (status != STORAGE_OK) {
- irc_free(irc);
- return status;
- }
-
- g_free(irc->nick);
- irc->nick = g_strdup(nnick);
-
- status = storage_save(irc, FALSE);
- if (status != STORAGE_OK) {
- irc_free(irc);
- return status;
- }
- irc_free(irc);
-
- storage_remove(onick, password);
-
- return STORAGE_OK;
-}
-#endif