mail-cache-transaction.c revision da5dd6f1141e8b134199e1a2a23af4e05173464a
de68e21ab7c82f21db445d619b211c7aaa6f22c9henning mueller/* Copyright (c) 2003-2007 Dovecot authors, see the included COPYING file */
#include "read-full.h"
#include "write-full.h"
#include "mail-cache-private.h"
#include "mail-index-transaction-private.h"
#include <stddef.h>
struct mail_cache_reservation {
struct mail_cache_transaction_ctx {
struct mail_cache_transaction_ctx *
struct mail_index_transaction *t)
return t->cache_trans_ctx;
return ctx;
int ret;
if (ret < 0)
while (offset != 0) {
return FALSE;
return FALSE;
if (offset == 0)
return FALSE;
if (prev_offset == 0)
return FALSE;
return TRUE;
unsigned int i, count;
for (i = 0; i < count; i++) {
unsigned int count;
count--;
if (!locked) {
if (!locked) {
bool commit)
int ret;
if (!locked) {
return ret;
commit);
if (!locked) {
if (ret < 0)
if (old_offset != 0) {
write_offset) < 0)
old_offset) < 0)
*seq_idx = i;
unsigned int seq_count;
int ret;
bool commit;
if (commit) {
seq_limit = 0;
if (ret <= 0) {
return ret;
seq_limit++;
&write_size) < 0)
void *data;
int ret = 0;
return ret;
unsigned int count;
while (count > 0) {
count--;
unsigned int field_idx)
int ret;
t_push();
t_pop();
if (ret == 0) {
return ret;
unsigned int fixed_size;
sizeof(data_size32));
return FALSE;
return FALSE;
t_push();
if (offset == 0) {
ret = 0;
t_pop();
return ret;