Subject: [merged] kernel-auditfilterc-fix-leak-in-audit_add_rule-error-path.patch removed from -mm tree To: gang.chen@xxxxxxxxxxx,eparis@xxxxxxxxxx,viro@xxxxxxxxxxxxxxxxxx,mm-commits@xxxxxxxxxxxxxxx From: akpm@xxxxxxxxxxxxxxxxxxxx Date: Tue, 09 Jul 2013 16:19:06 -0700 The patch titled Subject: kernel/auditfilter.c: fix leak in audit_add_rule() error path has been removed from the -mm tree. Its filename was kernel-auditfilterc-fix-leak-in-audit_add_rule-error-path.patch This patch was dropped because it was merged into mainline or a subsystem tree ------------------------------------------------------ From: Chen Gang <gang.chen@xxxxxxxxxxx> Subject: kernel/auditfilter.c: fix leak in audit_add_rule() error path If both 'tree' and 'watch' are valid we must call audit_put_tree(), just like the preceding code within audit_add_rule(). Signed-off-by: Chen Gang <gang.chen@xxxxxxxxxxx> Cc: Al Viro <viro@xxxxxxxxxxxxxxxxxx> Cc: Eric Paris <eparis@xxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- kernel/auditfilter.c | 6 ++++++ 1 file changed, 6 insertions(+) diff -puN kernel/auditfilter.c~kernel-auditfilterc-fix-leak-in-audit_add_rule-error-path kernel/auditfilter.c --- a/kernel/auditfilter.c~kernel-auditfilterc-fix-leak-in-audit_add_rule-error-path +++ a/kernel/auditfilter.c @@ -865,6 +865,12 @@ static inline int audit_add_rule(struct err = audit_add_watch(&entry->rule, &list); if (err) { mutex_unlock(&audit_filter_mutex); + /* + * normally audit_add_tree_rule() will free it + * on failure + */ + if (tree) + audit_put_tree(tree); goto error; } } _ Patches currently in -mm which might be from gang.chen@xxxxxxxxxxx are origin.patch linux-next.patch include-linux-interrupth-add-dummy-irq_set_irq_wake-for-generic_hardirqs.patch kernel-smpc-free-related-resources-when-failure-occurs-in-hotplug_cfd.patch -- To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html