dovecot-2.0: doveadm force-resync: Get mailbox name as UTF-8.
dovecot at dovecot.org
dovecot at dovecot.org
Fri May 28 14:28:02 EEST 2010
details: http://hg.dovecot.org/dovecot-2.0/rev/6f4bfa83aabd
changeset: 11411:6f4bfa83aabd
user: Timo Sirainen <tss at iki.fi>
date: Fri May 28 12:27:58 2010 +0100
description:
doveadm force-resync: Get mailbox name as UTF-8.
diffstat:
src/doveadm/doveadm-mail.c | 7 +++++++
1 files changed, 7 insertions(+), 0 deletions(-)
diffs (29 lines):
diff -r 2127b6e9096d -r 6f4bfa83aabd src/doveadm/doveadm-mail.c
--- a/src/doveadm/doveadm-mail.c Fri May 28 12:23:10 2010 +0100
+++ b/src/doveadm/doveadm-mail.c Fri May 28 12:27:58 2010 +0100
@@ -4,9 +4,11 @@
#include "array.h"
#include "lib-signals.h"
#include "ioloop.h"
+#include "str.h"
#include "module-dir.h"
#include "wildcard-match.h"
#include "master-service.h"
+#include "imap-utf7.h"
#include "mail-user.h"
#include "mail-namespace.h"
#include "mail-storage.h"
@@ -73,8 +75,13 @@
{
struct mail_namespace *ns;
struct mailbox *box;
+ string_t *str;
const char *orig_mailbox = mailbox;
+ str = t_str_new(128);
+ if (imap_utf8_to_utf7(mailbox, str) == 0)
+ mailbox = str_c(str);
+
ns = mail_namespace_find(user->namespaces, &mailbox);
if (ns == NULL)
i_fatal("Can't find namespace for mailbox %s", mailbox);
More information about the dovecot-cvs
mailing list