[dovecot-cvs] dovecot/src/lib-storage/index/maildir maildir-storage.c, 1.93, 1.94

cras at dovecot.org cras at dovecot.org
Tue Mar 29 16:33:10 EEST 2005


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

Modified Files:
	maildir-storage.c 
Log Message:
Added input stream parameter to mailbox_open(). With mbox it now allows
opening a read-only mbox using a stream.



Index: maildir-storage.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/index/maildir/maildir-storage.c,v
retrieving revision 1.93
retrieving revision 1.94
diff -u -d -r1.93 -r1.94
--- maildir-storage.c	15 Mar 2005 19:01:52 -0000	1.93
+++ maildir-storage.c	29 Mar 2005 13:33:07 -0000	1.94
@@ -446,8 +446,8 @@
 }
 
 static struct mailbox *
-maildir_mailbox_open(struct mail_storage *_storage,
-		     const char *name, enum mailbox_open_flags flags)
+maildir_mailbox_open(struct mail_storage *_storage, const char *name,
+		     struct istream *input, enum mailbox_open_flags flags)
 {
 	struct index_storage *storage = (struct index_storage *)_storage;
 	const char *path;
@@ -455,6 +455,12 @@
 
 	mail_storage_clear_error(_storage);
 
+	if (input != NULL) {
+		mail_storage_set_critical(_storage,
+			"Maildir doesn't support streamed mailboxes");
+		return NULL;
+	}
+
 	if (strcmp(name, "INBOX") == 0) {
 		if (verify_inbox(storage) < 0)
 			return NULL;



More information about the dovecot-cvs mailing list