index-transaction.c revision ab9a91eb05a54f7675e0bf861aca53f417e1980d
/* Copyright (c) 2003-2011 Dovecot authors, see the included COPYING file */
#include "lib.h"
#include "array.h"
#include "index-storage.h"
#include "index-mail.h"
static void index_transaction_free(struct mailbox_transaction_context *t)
{
mail_index_view_close(&t->view);
array_free(&t->module_contexts);
i_free(t);
}
static int
{
struct mailbox_transaction_context *t =
int ret = 0;
ret = -1;
}
}
i_assert(t->mail_ref_count == 0);
if (ret < 0)
else {
ret = -1;
}
}
return ret;
}
static void
{
struct mailbox_transaction_context *t =
i_assert(t->mail_ref_count == 0);
}
void index_transaction_init(struct mailbox_transaction_context *t,
{
if ((flags & MAILBOX_TRANSACTION_FLAG_HIDE) != 0)
if ((flags & MAILBOX_TRANSACTION_FLAG_EXTERNAL) != 0)
if ((flags & MAILBOX_TRANSACTION_FLAG_REFRESH) != 0)
sizeof(void *), 5);
if ((flags & MAILBOX_TRANSACTION_FLAG_NO_CACHE_DEC) != 0)
/* set up after mail_cache_get_transaction(), so that we'll still
have the cache_trans available in _index_commit() */
}
struct mailbox_transaction_context *
{
struct mailbox_transaction_context *t;
return t;
}
int index_transaction_commit(struct mailbox_transaction_context *t,
struct mail_transaction_commit_changes *changes_r)
{
int ret;
"transaction changes", 512);
t = NULL;
return ret;
}
void index_transaction_rollback(struct mailbox_transaction_context *t)
{
}