quota-dict.c revision 9844b5359f5cab77e4c31a7ac9e4a60a0073929e
/* Copyright (C) 2005 Timo Sirainen */
#include "lib.h"
#include "str.h"
#include "dict.h"
#include "quota-private.h"
#include <stdlib.h>
struct dict_quota {
const char *error;
struct quota_root root;
};
struct dict_quota_root_iter {
struct quota_root_iter iter;
bool sent;
};
extern struct quota dict_quota;
{
struct dict_quota *quota;
return NULL;
}
{
}
static struct quota_root_iter *
{
struct dict_quota_root_iter *iter;
}
static struct quota_root *
{
struct dict_quota_root_iter *iter =
(struct dict_quota_root_iter *)_iter;
return NULL;
}
{
return 0;
}
static struct quota_root *
{
if (*name == '\0')
else
return NULL;
}
static const char *
{
return "";
}
static const char *const *
{
return resources;
}
static int
const char *name __attr_unused__,
{
return -1;
}
static int
{
const char *value;
int ret;
return 0;
t_push();
&value);
/* resource doesn't exist */
*value_r = 0;
} else {
}
t_pop();
*limit_r /= 1024;
*value_r /= 1024;
return ret;
}
static int
const char *name __attr_unused__,
{
return -1;
}
static struct quota_transaction_context *
{
struct quota_transaction_context *ctx;
const char *value;
t_push();
t_pop();
} else {
}
return ctx;
}
static int
{
struct dict_transaction_context *dt;
ctx->bytes_diff);
if (dict_transaction_commit(dt) < 0)
i_error("dict_quota: Couldn't update quota");
}
return 0;
}
static void
{
}
static int
{
return -1;
return 0;
return 1;
}
static void
{
}
static void
{
}
{
}
struct quota dict_quota = {
"dict",
};