tomoyo: fix memory leak in tomoyo_commit_ok()
authorXiaochen Wang <wangxiaochen0@gmail.com>
Wed, 30 Mar 2011 15:27:32 +0000 (00:27 +0900)
committerJames Morris <jmorris@namei.org>
Wed, 30 Mar 2011 23:25:06 +0000 (10:25 +1100)
When memory used for policy exceeds the quota, tomoyo_memory_ok() return false.
In this case, tomoyo_commit_ok() must call kfree() before returning NULL.
This bug exists since 2.6.35.

Signed-off-by: Xiaochen Wang <wangxiaochen0@gmail.com>
Acked-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Signed-off-by: James Morris <jmorris@namei.org>

No differences found