From faeaff460d763bb4b574d31d78773f91aaba5510 Mon Sep 17 00:00:00 2001 From: Timo Sirainen Date: Mon, 28 Sep 2009 14:24:14 -0400 Subject: [PATCH] quota: Don't crash with non-Maildir++ quota backend. Patch by Brandon Davidson. --HG-- branch : HEAD --- src/plugins/quota/quota.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/plugins/quota/quota.c b/src/plugins/quota/quota.c index 2db8f437e9..40675572ef 100644 --- a/src/plugins/quota/quota.c +++ b/src/plugins/quota/quota.c @@ -507,8 +507,10 @@ static int quota_root_get_rule_limits(struct quota_root *root, bool found; if (!root->set->force_default_rule) { - if (root->backend.v.init_limits(root) < 0) - return -1; + if (root->backend.v.init_limits != NULL) { + if (root->backend.v.init_limits(root) < 0) + return -1; + } } bytes_limit = root->bytes_limit; -- 2.47.3