replication-plugin.c revision 152a3748e4c43e0fed074e0aeff306dd0d222842
e8f60d1e2b57b95839ffe93359dad541a4eceb19Eugen Kuksa/* Copyright (c) 2013 Dovecot authors, see the included COPYING file */
#include "net.h"
#include "write-full.h"
#include "mail-user.h"
#include "mail-namespace.h"
#include "mail-storage-private.h"
#include "notify-plugin.h"
#include "replication-common.h"
#include "replication-plugin.h"
#include <stdlib.h>
struct replication_user {
const char *socket_path;
unsigned int sync_secs;
struct replication_mail_txn_context {
bool new_messages;
static int fifo_fd;
static bool fifo_failed;
static char *fifo_path;
if (fifo_failed)
switch (priority) {
i_unreached();
case REPLICATION_PRIORITY_LOW:
if (ret == 0) {
if (ret < 0)
int ret;
!fifo_failed) {
if (ret != 0) {
int fd;
if (ret < 0) {
} else if (ret == 0) {
ret = 0;
alarm(0);
return ret;
return ctx;
const char *value;
void replication_plugin_deinit(void)