Mercurial > dovecot > core-2.2
changeset 11547:d24cd07babb6 HEAD
lib-storage: Use macros instead of magic '0' and '1' characters.
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Mon, 14 Jun 2010 20:41:23 +0100 |
parents | 6e1247609440 |
children | d15d5d828d6b |
files | src/lib-storage/mailbox-list.c |
diffstat | 1 files changed, 5 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/src/lib-storage/mailbox-list.c Mon Jun 14 20:39:06 2010 +0100 +++ b/src/lib-storage/mailbox-list.c Mon Jun 14 20:41:23 2010 +0100 @@ -13,6 +13,7 @@ #include "write-full.h" #include "safe-mkstemp.h" #include "unlink-directory.h" +#include "settings-parser.h" #include "imap-match.h" #include "imap-utf7.h" #include "mailbox-log.h" @@ -315,12 +316,12 @@ struct mailbox_list_settings set; const char *p, *error; - if (*location == '1') { + if (*location == SETTING_STRVAR_EXPANDED[0]) { /* set using -o or userdb lookup. */ return ""; } - i_assert(*location == '0'); + i_assert(*location == SETTING_STRVAR_UNEXPANDED[0]); location++; if (*location == '\0') { @@ -328,9 +329,9 @@ user->unexpanded_set, MAIL_STORAGE_SET_DRIVER_NAME); i_assert(mail_set != NULL); location = mail_set->mail_location; - if (*location == '1') + if (*location == SETTING_STRVAR_EXPANDED[0]) return ""; - i_assert(*location == '0'); + i_assert(*location == SETTING_STRVAR_UNEXPANDED[0]); location++; }