dovecot-2.2: director: If doveadm attempts to change tag for an ...

dovecot at dovecot.org dovecot at dovecot.org
Wed Dec 9 11:03:08 UTC 2015


details:   http://hg.dovecot.org/dovecot-2.2/rev/1d2999cfe0a4
changeset: 19497:1d2999cfe0a4
user:      Timo Sirainen <tss at iki.fi>
date:      Wed Dec 09 13:02:46 2015 +0200
description:
director: If doveadm attempts to change tag for an existing host, return error.

diffstat:

 src/director/doveadm-connection.c |  3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diffs (13 lines):

diff -r 13afb0912164 -r 1d2999cfe0a4 src/director/doveadm-connection.c
--- a/src/director/doveadm-connection.c	Wed Dec 09 13:02:19 2015 +0200
+++ b/src/director/doveadm-connection.c	Wed Dec 09 13:02:46 2015 +0200
@@ -282,6 +282,9 @@
 			return TRUE;
 		}
 		host = mail_host_add_ip(dir->mail_hosts, &ip, tag);
+	} else if (tag[0] != '\0' && strcmp(mail_host_get_tag(host), tag) != 0) {
+		o_stream_nsend_str(conn->output, "host tag can't be changed\n");
+		return TRUE;
 	} else if (host->desynced) {
 		o_stream_nsend_str(conn->output,
 			"host is already being updated - try again later\n");


More information about the dovecot-cvs mailing list