dovecot-2.0: imap: STATUS (X-GUID) added extra space to result.
dovecot at dovecot.org
dovecot at dovecot.org
Wed Jun 9 21:22:26 EEST 2010
details: http://hg.dovecot.org/dovecot-2.0/rev/425f635ebaa9
changeset: 11513:425f635ebaa9
user: Timo Sirainen <tss at iki.fi>
date: Wed Jun 09 19:22:23 2010 +0100
description:
imap: STATUS (X-GUID) added extra space to result.
diffstat:
src/imap/imap-status.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diffs (27 lines):
diff -r 3dfe1690b568 -r 425f635ebaa9 src/imap/imap-status.c
--- a/src/imap/imap-status.c Wed Jun 09 18:53:40 2010 +0100
+++ b/src/imap/imap-status.c Wed Jun 09 19:22:23 2010 +0100
@@ -107,12 +107,14 @@
{
const struct mailbox_status *status = &result->status;
string_t *str;
+ unsigned int prefix_len;
str = t_str_new(128);
str_append(str, "* STATUS ");
imap_quote_append_string(str, mailbox, FALSE);
str_append(str, " (");
+ prefix_len = str_len(str);
if ((items->mailbox_items & STATUS_MESSAGES) != 0)
str_printfa(str, "MESSAGES %u ", status->messages);
if ((items->mailbox_items & STATUS_RECENT) != 0)
@@ -136,7 +138,7 @@
mail_guid_128_to_string(result->mailbox_guid));
}
- if (items != 0)
+ if (str_len(str) != prefix_len)
str_truncate(str, str_len(str)-1);
str_append_c(str, ')');
More information about the dovecot-cvs
mailing list