Mercurial > dovecot > core-2.2
changeset 11743:cd0d3392366e HEAD
dsync: Refuse to run if we detect virtual hierarchy separators differ for mail locations.
The real separators can differ, but to work properly there must be a default
namespace with a separator defined.
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Tue, 06 Jul 2010 19:14:39 +0100 |
parents | ab2670833cb7 |
children | 912a11f476cc |
files | src/dsync/dsync.c |
diffstat | 1 files changed, 8 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/src/dsync/dsync.c Tue Jul 06 18:52:16 2010 +0100 +++ b/src/dsync/dsync.c Tue Jul 06 19:14:39 2010 +0100 @@ -8,6 +8,7 @@ #include "master-service-settings.h" #include "mail-storage-service.h" #include "mail-user.h" +#include "mail-namespace.h" #include "dsync-brain.h" #include "dsync-worker.h" #include "dsync-proxy-server.h" @@ -256,6 +257,13 @@ &mail_user2) < 0) i_fatal("User init failed"); + if (mail_namespaces_get_root_sep(mail_user->namespaces) != + mail_namespaces_get_root_sep(mail_user2->namespaces)) { + i_fatal("Mail locations must use the same " + "virtual mailbox hierarchy separator " + "(specify separator for the default namespace)"); + } + worker2 = dsync_worker_init_local(mail_user2, alt_char); if (reverse_workers) { workertmp = worker1;