view src/lib-lda/duplicate.h @ 22656:1789bf2a1e01

director: Make sure HOST-RESET-USERS isn't used with max_moving_users=0 The reset command would just hang in that case. doveadm would never have sent this, so this is just an extra sanity check.
author Timo Sirainen <timo.sirainen@dovecot.fi>
date Sun, 05 Nov 2017 23:51:56 +0200
parents d0a24521d13f
children
line wrap: on
line source

#ifndef DUPLICATE_H
#define DUPLICATE_H

struct duplicate_context;
struct mail_storage_settings;

#define DUPLICATE_DEFAULT_KEEP (3600 * 24)

bool duplicate_check(struct duplicate_context *ctx,
		     const void *id, size_t id_size, const char *user);
void duplicate_mark(struct duplicate_context *ctx,
		    const void *id, size_t id_size,
                    const char *user, time_t timestamp);

void duplicate_flush(struct duplicate_context *ctx);

struct duplicate_context *duplicate_init(struct mail_user *user);
void duplicate_deinit(struct duplicate_context **ctx);

#endif