/* update mail_location and create another user for the
second location. */
- if (mail_storage_service_user_set_setting(ctx->ctx.cur_service_user,
- "mail_location", location,
- &error) <= 0)
+ struct setting_parser_context *set_parser =
+ mail_storage_service_user_get_settings_parser(ctx->ctx.cur_service_user);
+ if (master_service_set(set_parser, "mail_location", location, &error) <= 0)
i_unreached();
ret = mail_storage_service_next(ctx->ctx.storage_service,
ctx->ctx.cur_service_user,
#include "module-dir.h"
#include "wildcard-match.h"
#include "master-service.h"
+#include "master-service-settings.h"
#include "mail-user.h"
#include "mail-namespace.h"
#include "mail-storage.h"
struct mail_storage_service_user *service_user,
const char **error_r)
{
- if (mail_storage_service_user_set_setting(service_user,
- "mailbox_list_index_very_dirty_syncs",
- "no",
- error_r) <= 0)
+ struct setting_parser_context *set_parser =
+ mail_storage_service_user_get_settings_parser(service_user);
+ if (master_service_set(set_parser, "mailbox_list_index_very_dirty_syncs",
+ "no", error_r) <= 0)
i_unreached();
return 0;
}
return;
}
- if (mail_storage_service_user_set_setting(user, key, value, &error) < 0)
+ if (master_service_set(user->set_parser, key, value, &error) < 0)
i_fatal("Invalid userdb input %s=%s: %s", key, value, error);
}
value = t_strconcat(*strp, append_value, NULL);
}
- ret = mail_storage_service_user_set_setting(user, key, value, error_r);
+ ret = master_service_set(user->set_parser, key, value, error_r);
if (ret < 0)
return -1;
if (strstr(key, "pass") != NULL) {
var_expand_ctx.user = user;
if ((flags & MAIL_STORAGE_SERVICE_FLAG_DEBUG) != 0) {
- if (mail_storage_service_user_set_setting(user, "mail_debug", "yes", &error) <= 0)
+ if (master_service_set(user->set_parser, "mail_debug", "yes", &error) <= 0)
i_unreached();
}
fine that extra plugins are loaded - we'll just need to
prevent any of their hooks from being called. One easy way
to do this is just to clear out the mail_plugins setting: */
- if (mail_storage_service_user_set_setting(user, "mail_plugins", "", &error) <= 0)
+ if (master_service_set(user->set_parser, "mail_plugins", "", &error) <= 0)
i_unreached();
}
if (ret > 0) {
advertised that it's going to timeout the connection.
this avoids duplicate deliveries in case the delivery
succeeds after the proxy has already disconnected from us. */
+ struct setting_parser_context *set_parser =
+ mail_storage_service_user_get_settings_parser(service_user);
const char *value = t_strdup_printf("%us",
proxy_data.timeout_secs <= 1 ? 1 :
proxy_data.timeout_secs-1);
- if (mail_storage_service_user_set_setting(service_user,
- "mail_max_lock_timeout", value, &error) <= 0)
+ if (master_service_set(set_parser, "mail_max_lock_timeout",
+ value, &error) <= 0)
i_unreached();
}
master_service_settings_free(mail_set);