[dovecot-cvs] dovecot/src/lib-storage/index/mbox mbox-storage.c, 1.169, 1.170

tss at dovecot.org tss at dovecot.org
Tue Mar 27 22:59:34 EEST 2007


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

Modified Files:
	mbox-storage.c 
Log Message:
Disable index files if index directory can't be created.



Index: mbox-storage.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/index/mbox/mbox-storage.c,v
retrieving revision 1.169
retrieving revision 1.170
diff -u -d -r1.169 -r1.170
--- mbox-storage.c	25 Mar 2007 23:18:49 -0000	1.169
+++ mbox-storage.c	27 Mar 2007 19:59:31 -0000	1.170
@@ -468,8 +468,10 @@
 		return 0;
 
 	if (mkdir_parents(index_dir, CREATE_MODE) < 0) {
-		mail_storage_set_critical(storage,
-			"mkdir_parents(%s) failed: %m", index_dir);
+		if (!ENOSPACE(errno)) {
+			mail_storage_set_critical(storage,
+				"mkdir_parents(%s) failed: %m", index_dir);
+		}
 		return -1;
 	}
 
@@ -604,7 +606,7 @@
 	if (*index_dir != '\0') {
 		/* make sure the index directories exist */
 		if (create_mbox_index_dirs(_storage, name) < 0)
-			return NULL;
+			index_dir = "";
 	}
 
 	index = index_storage_alloc(index_dir, path, MBOX_INDEX_PREFIX);
@@ -643,7 +645,7 @@
 
 		/* make sure the required directories are also there */
 		if (create_mbox_index_dirs(_storage, name) < 0)
-			return NULL;
+			index_dir = "";
 	}
 
 	index = index_storage_alloc(index_dir, path, MBOX_INDEX_PREFIX);



More information about the dovecot-cvs mailing list