security: smack: fix memleak in smk_write_rules_list()
authorTomasz Stanislawski <t.stanislaws@samsung.com>
Thu, 6 Jun 2013 07:30:50 +0000 (09:30 +0200)
committerCasey Schaufler <casey@schaufler-ca.com>
Thu, 1 Aug 2013 19:57:24 +0000 (12:57 -0700)
The smack_parsed_rule structure is allocated.  If a rule is successfully
installed then the last reference to the object is lost.  This patch fixes this
leak. Moreover smack_parsed_rule is allocated on stack because it no longer
needed ofter smk_write_rules_list() is finished.

Signed-off-by: Tomasz Stanislawski <t.stanislaws@samsung.com>

No differences found