TOMOYO: Fix quota check.
authorTetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Tue, 27 Jul 2010 01:08:29 +0000 (10:08 +0900)
committerJames Morris <jmorris@namei.org>
Mon, 2 Aug 2010 05:35:09 +0000 (15:35 +1000)
Commit d74725b9 "TOMOYO: Use callback for updating entries." broke
tomoyo_domain_quota_is_ok() by counting deleted entries. It needs to
count non-deleted entries.

Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Signed-off-by: James Morris <jmorris@namei.org>
security/tomoyo/util.c

index 150167d0cc3a11f3c7fc6587ed76e3cd988e779c..9bfc1ee8222ddf6c9edadb48067e5384f0598e8c 100644 (file)
@@ -911,7 +911,7 @@ bool tomoyo_domain_quota_is_ok(struct tomoyo_request_info *r)
        if (!domain)
                return true;
        list_for_each_entry_rcu(ptr, &domain->acl_info_list, list) {
-               if (!ptr->is_deleted)
+               if (ptr->is_deleted)
                        continue;
                switch (ptr->type) {
                        u16 perm;