[dovecot-cvs] dovecot/src/lib-storage/index/mbox mbox-list.c, 1.37, 1.38

cras at dovecot.org cras at dovecot.org
Sat Apr 1 13:44:12 EEST 2006


Update of /var/lib/cvs/dovecot/src/lib-storage/index/mbox
In directory talvi:/tmp/cvs-serv12938/lib-storage/index/mbox

Modified Files:
	mbox-list.c 
Log Message:
Hide also "." and ".." when listing mboxes



Index: mbox-list.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/index/mbox/mbox-list.c,v
retrieving revision 1.37
retrieving revision 1.38
diff -u -d -r1.37 -r1.38
--- mbox-list.c	1 Apr 2006 09:36:25 -0000	1.37
+++ mbox-list.c	1 Apr 2006 10:44:10 -0000	1.38
@@ -223,9 +223,11 @@
 	int ret;
 	bool noselect;
 
-	/* skip subscription file and .imap/ directory */
+	/* skip ., .., subscription file and .imap/ directory */
 	if (fname[0] == '.' &&
-	    (strcmp(fname, SUBSCRIPTION_FILE_NAME) == 0 ||
+	    (fname[1] == '\0' ||
+	     (fname[1] == '.' && fname[2] == '\0') ||
+	     strcmp(fname, SUBSCRIPTION_FILE_NAME) == 0 ||
 	     strcmp(fname, MBOX_INDEX_DIR_NAME) == 0))
 		return 0;
 



More information about the dovecot-cvs mailing list