[dovecot-cvs] dovecot/src/lib-storage/index/mbox mbox-storage.c, 1.177, 1.178
tss at dovecot.org
tss at dovecot.org
Fri Mar 30 21:32:15 EEST 2007
Update of /var/lib/cvs/dovecot/src/lib-storage/index/mbox
In directory talvi:/tmp/cvs-serv29314/index/mbox
Modified Files:
mbox-storage.c
Log Message:
mailbox_open/create: Moved the mailbox name validation and error clearing
into common mail-storage.c
Index: mbox-storage.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/index/mbox/mbox-storage.c,v
retrieving revision 1.177
retrieving revision 1.178
diff -u -d -r1.177 -r1.178
--- mbox-storage.c 30 Mar 2007 18:28:36 -0000 1.177
+++ mbox-storage.c 30 Mar 2007 18:32:10 -0000 1.178
@@ -651,8 +651,6 @@
const char *path, *error;
struct stat st;
- mail_storage_clear_error(_storage);
-
if (input != NULL)
return mbox_mailbox_open_stream(storage, name, input, flags);
@@ -663,11 +661,6 @@
return mbox_open(storage, "INBOX", flags);
}
- if (!mailbox_list_is_valid_existing_name(_storage->list, name)) {
- mail_storage_set_error(_storage, "Invalid mailbox name");
- return NULL;
- }
-
path = mailbox_list_get_path(_storage->list, name,
MAILBOX_LIST_PATH_TYPE_MAILBOX);
if (stat(path, &st) == 0) {
@@ -700,12 +693,6 @@
struct stat st;
int fd;
- mail_storage_clear_error(_storage);
-
- if (!mailbox_list_is_valid_create_name(_storage->list, name)) {
- mail_storage_set_error(_storage, "Invalid mailbox name");
- return -1;
- }
/* make sure it doesn't exist already */
path = mailbox_list_get_path(_storage->list, name,
More information about the dovecot-cvs
mailing list