Use account ID instead of name in passwordstorerc.
[claws.git] / src / plugins / managesieve / managesieve.c
index 1311172912c1373c9a818525f2e06f6677ad6c24..0fb4ac74d1bce9d71ff286ae7d9eb2819f569543 100644 (file)
@@ -1056,10 +1056,10 @@ static void sieve_session_reset(SieveSession *session)
                g_free(session->pass);
        if (config->auth == SIEVEAUTH_NONE) {
                session->pass = NULL;
-       } else if (reuse_auth && (session->pass = passwd_store_get(PWS_ACCOUNT,
-                                account->account_name, PWS_ACCOUNT_RECV))) {
-       } else if ((session->pass = passwd_store_get(PWS_ACCOUNT,
-                                account->account_name, "sieve"))) {
+       } else if (reuse_auth && (session->pass = passwd_store_get_account(
+                                account->account_id, PWS_ACCOUNT_RECV))) {
+       } else if ((session->pass = passwd_store_get_account(
+                                account->account_id, "sieve"))) {
        } else if (password_get(session->user, session->host, "sieve",
                                session->port, &session->pass)) {
        } else {