Mercurial > dovecot > core-2.2
changeset 21757:9d825e599eb3
imap-hibernate: Avoid using casts
author | Timo Sirainen <timo.sirainen@dovecot.fi> |
---|---|
date | Wed, 01 Mar 2017 13:12:41 +0200 |
parents | 014edbaf5ab6 |
children | 343344fec13a |
files | src/imap-hibernate/imap-client.c |
diffstat | 1 files changed, 4 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/src/imap-hibernate/imap-client.c Wed Mar 01 09:15:29 2017 +0200 +++ b/src/imap-hibernate/imap-client.c Wed Mar 01 13:12:41 2017 +0200 @@ -495,7 +495,7 @@ static const char * imap_client_var_expand_func_userdb(const char *data, void *context) { - const char *const *fields = (const char *const *)context; + const char *const *fields = context; const char *field_name = t_strdup_printf("%s=",t_strcut(data, ':')); const char *default_value = i_strchr_to_next(data, ':'); const char *value = NULL; @@ -563,12 +563,12 @@ } T_BEGIN { string_t *str; - const char *const *fields = - t_strsplit_tabescaped(client->state.userdb_fields); + char **fields = p_strsplit_tabescaped(unsafe_data_stack_pool, + client->state.userdb_fields); str = t_str_new(256); var_expand_with_funcs(str, state->mail_log_prefix, imap_client_get_var_expand_table(client), - funcs, (void*)fields); + funcs, fields); client->log_prefix = p_strdup(pool, str_c(str)); } T_END;