dovecot-1.1: If SORT/THREAD has invalid search parameters, retur...

dovecot at dovecot.org dovecot at dovecot.org
Thu May 29 19:11:36 EEST 2008


details:   http://hg.dovecot.org/dovecot-1.1/rev/443dcddf9a9a
changeset: 7571:443dcddf9a9a
user:      Timo Sirainen <tss at iki.fi>
date:      Thu May 29 19:08:05 2008 +0300
description:
If SORT/THREAD has invalid search parameters, return BAD instead of NO.

diffstat:

2 files changed, 2 insertions(+), 2 deletions(-)
src/imap/cmd-sort.c   |    2 +-
src/imap/cmd-thread.c |    2 +-

diffs (24 lines):

diff -r 2220b2aa9f7c -r 443dcddf9a9a src/imap/cmd-sort.c
--- a/src/imap/cmd-sort.c	Thu May 29 18:57:56 2008 +0300
+++ b/src/imap/cmd-sort.c	Thu May 29 19:08:05 2008 +0300
@@ -130,7 +130,7 @@ bool cmd_sort(struct client_command_cont
 	sargs = imap_search_args_build(pool, client->mailbox, args, &error);
 	if (sargs == NULL) {
 		/* error in search arguments */
-		client_send_tagline(cmd, t_strconcat("NO ", error, NULL));
+		client_send_tagline(cmd, t_strconcat("BAD ", error, NULL));
 	} else if (imap_sort(cmd, charset, sargs, sorting) == 0) {
 		pool_unref(&pool);
 		return cmd_sync(cmd, MAILBOX_SYNC_FLAG_FAST |
diff -r 2220b2aa9f7c -r 443dcddf9a9a src/imap/cmd-thread.c
--- a/src/imap/cmd-thread.c	Thu May 29 18:57:56 2008 +0300
+++ b/src/imap/cmd-thread.c	Thu May 29 19:08:05 2008 +0300
@@ -63,7 +63,7 @@ bool cmd_thread(struct client_command_co
 	sargs = imap_search_args_build(pool, client->mailbox, args, &error);
 	if (sargs == NULL) {
 		/* error in search arguments */
-		client_send_tagline(cmd, t_strconcat("NO ", error, NULL));
+		client_send_tagline(cmd, t_strconcat("BAD ", error, NULL));
 	} else if (imap_thread(cmd, charset, sargs, threading) == 0) {
 		pool_unref(&pool);
 		return cmd_sync(cmd, MAILBOX_SYNC_FLAG_FAST |


More information about the dovecot-cvs mailing list