[dovecot-cvs] dovecot/src/lib-storage mail-storage-private.h, 1.54, 1.55 mail-storage.c, 1.81, 1.82 mail-storage.h, 1.131, 1.132
tss at dovecot.org
tss at dovecot.org
Sun May 13 18:46:10 EEST 2007
Update of /var/lib/cvs/dovecot/src/lib-storage
In directory talvi:/tmp/cvs-serv17914/lib-storage
Modified Files:
mail-storage-private.h mail-storage.c mail-storage.h
Log Message:
lib-storage doesn't need the ability to return syntax errors. They should be
checked before lib-storage is called.
Index: mail-storage-private.h
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/mail-storage-private.h,v
retrieving revision 1.54
retrieving revision 1.55
diff -u -d -r1.54 -r1.55
--- mail-storage-private.h 17 Apr 2007 16:40:55 -0000 1.54
+++ mail-storage-private.h 13 May 2007 15:46:08 -0000 1.55
@@ -66,8 +66,6 @@
/* Module-specific contexts. See mail_storage_module_id. */
ARRAY_DEFINE(module_contexts, union mail_storage_module_context *);
- /* IMAP: Give a BAD reply instead of NO */
- unsigned int syntax_error:1;
/* Internal temporary error, as opposed to visible user errors like
"permission denied" or "out of disk space" */
unsigned int temporary_error:1;
@@ -292,14 +290,11 @@
void mail_storage_clear_error(struct mail_storage *storage);
void mail_storage_set_error(struct mail_storage *storage,
const char *fmt, ...) __attr_format__(2, 3);
-void mail_storage_set_syntax_error(struct mail_storage *storage,
- const char *fmt, ...) __attr_format__(2, 3);
void mail_storage_set_critical(struct mail_storage *storage,
const char *fmt, ...) __attr_format__(2, 3);
void mail_storage_set_internal_error(struct mail_storage *storage);
-const char *mail_storage_class_get_last_error(struct mail_storage *storage,
- bool *syntax_error_r);
+const char *mail_storage_class_get_last_error(struct mail_storage *storage);
enum mailbox_list_flags
mail_storage_get_list_flags(enum mail_storage_flags storage_flags);
Index: mail-storage.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/mail-storage.c,v
retrieving revision 1.81
retrieving revision 1.82
diff -u -d -r1.81 -r1.82
--- mail-storage.c 17 Apr 2007 16:40:55 -0000 1.81
+++ mail-storage.c 13 May 2007 15:46:08 -0000 1.82
@@ -236,7 +236,6 @@
i_free(storage->error);
storage->error = NULL;
- storage->syntax_error = FALSE;
storage->temporary_error = FALSE;
}
@@ -253,21 +252,6 @@
}
}
-void mail_storage_set_syntax_error(struct mail_storage *storage,
- const char *fmt, ...)
-{
- va_list va;
-
- mail_storage_clear_error(storage);
-
- if (fmt != NULL) {
- va_start(va, fmt);
- storage->error = i_strdup_vprintf(fmt, va);
- storage->syntax_error = TRUE;
- va_end(va);
- }
-}
-
void mail_storage_set_internal_error(struct mail_storage *storage)
{
struct tm *tm;
@@ -279,7 +263,6 @@
storage->error =
strftime(str, sizeof(str), CRITICAL_MSG_STAMP, tm) > 0 ?
i_strdup(str) : i_strdup(CRITICAL_MSG);
- storage->syntax_error = FALSE;
storage->temporary_error = TRUE;
}
@@ -291,7 +274,6 @@
storage->error =
i_strdup(mailbox_list_get_last_error(storage->list, &temp));
- storage->syntax_error = FALSE;
storage->temporary_error = temp;
}
@@ -350,10 +332,8 @@
}
const char *mail_storage_get_last_error(struct mail_storage *storage,
- bool *syntax_error_r,
bool *temporary_error_r)
{
- *syntax_error_r = storage->syntax_error;
*temporary_error_r = storage->temporary_error;
/* We get here only in error situations, so we have to return some
Index: mail-storage.h
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/mail-storage.h,v
retrieving revision 1.131
retrieving revision 1.132
diff -u -d -r1.131 -r1.132
--- mail-storage.h 17 Apr 2007 16:40:55 -0000 1.131
+++ mail-storage.h 13 May 2007 15:46:08 -0000 1.132
@@ -231,7 +231,6 @@
/* Returns the error message of last occurred error. */
const char *mail_storage_get_last_error(struct mail_storage *storage,
- bool *syntax_error_r,
bool *temporary_error_r);
/* Returns path to the given mailbox, or NULL if mailbox doesn't exist in
More information about the dovecot-cvs
mailing list