diff src/lib-storage/index/dbox-common/dbox-sync-rebuild.c @ 14037:aed3379df476

lib-storage: mailbox_list_mkdir_root() API changed. Use it now for creating mail root dir. It was supposed to be used for it previously, but wasn't..
author Timo Sirainen <tss@iki.fi>
date Wed, 01 Feb 2012 20:10:42 +0200
parents c4bac1e48611
children d8d214cc1936
line wrap: on
line diff
--- a/src/lib-storage/index/dbox-common/dbox-sync-rebuild.c	Wed Feb 01 18:55:54 2012 +0200
+++ b/src/lib-storage/index/dbox-common/dbox-sync-rebuild.c	Wed Feb 01 20:10:42 2012 +0200
@@ -194,7 +194,7 @@
 
 int dbox_sync_rebuild_verify_alt_storage(struct mailbox_list *list)
 {
-	const char *alt_path;
+	const char *alt_path, *error;
 	struct stat st;
 
 	alt_path = mailbox_list_get_path(list, NULL,
@@ -213,7 +213,11 @@
 	/* try to create the alt directory. if it fails, it means alt
 	   storage isn't mounted. */
 	if (mailbox_list_mkdir_root(list, alt_path,
-				    MAILBOX_LIST_PATH_TYPE_ALT_DIR) < 0)
+				    MAILBOX_LIST_PATH_TYPE_ALT_DIR,
+				    &error) < 0) {
+		i_error("Couldn't create dbox alt root dir %s: %s",
+			alt_path, error);
 		return -1;
+	}
 	return 0;
 }