dovecot-2.0: lib-storage: Fixed expanding "~" (without '/' after...

dovecot at dovecot.org dovecot at dovecot.org
Tue Nov 9 20:36:41 EET 2010


details:   http://hg.dovecot.org/dovecot-2.0/rev/d1cf770dbef5
changeset: 12404:d1cf770dbef5
user:      Timo Sirainen <tss at iki.fi>
date:      Tue Nov 09 18:36:37 2010 +0000
description:
lib-storage: Fixed expanding "~" (without '/' afterwards) in mail_location

diffstat:

 src/lib-storage/mailbox-list.c |  2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diffs (12 lines):

diff -r f859a6e06b62 -r d1cf770dbef5 src/lib-storage/mailbox-list.c
--- a/src/lib-storage/mailbox-list.c	Mon Nov 08 19:55:35 2010 +0000
+++ b/src/lib-storage/mailbox-list.c	Tue Nov 09 18:36:37 2010 +0000
@@ -205,7 +205,7 @@
 
 	if (len > 1 && path[len-1] == '/')
 		path = t_strndup(path, len-1);
-	if (path[0] == '~' && path[1] != '/') {
+	if (path[0] == '~' && path[1] != '/' && path[1] != '\0') {
 		/* ~otheruser/dir */
 		if (home_try_expand(&path) < 0) {
 			*error_r = t_strconcat(


More information about the dovecot-cvs mailing list