This patch doesn't apply on .37-stable as this function isn't even there. Are you sure you want me to apply it? :)
thanks, greg k-h On Tue, Jan 25, 2011 at 08:43:20AM +1100, James Morris wrote: > ---------- Forwarded message ---------- > Date: Mon, 24 Jan 2011 10:59:04 GMT > From: Linux Kernel Mailing List <[email protected]> > To: [email protected] > Subject: trusted keys: Fix a memory leak in trusted_update(). > > Gitweb: > http://git.kernel.org/linus/5403110943a2dcf1f96416d7a412a8b46895facd > Commit: 5403110943a2dcf1f96416d7a412a8b46895facd > Parent: 7f3c68bee977ab872827e44de017216736fe21d7 > Author: Jesper Juhl <[email protected]> > AuthorDate: Sun Jan 23 22:40:42 2011 +0100 > Committer: James Morris <[email protected]> > CommitDate: Mon Jan 24 10:59:58 2011 +1100 > > trusted keys: Fix a memory leak in trusted_update(). > > One failure path in security/keys/trusted.c::trusted_update() does > not free 'new_p' while the others do. This patch makes sure we also free > it in the remaining path (if datablob_parse() returns different from > Opt_update). > > Signed-off-by: Jesper Juhl <[email protected]> > Signed-off-by: James Morris <[email protected]> > --- > security/keys/trusted.c | 1 + > 1 files changed, 1 insertions(+), 0 deletions(-) > > diff --git a/security/keys/trusted.c b/security/keys/trusted.c > index 3066f56..83fc92e 100644 > --- a/security/keys/trusted.c > +++ b/security/keys/trusted.c > @@ -1032,6 +1032,7 @@ static int trusted_update(struct key *key, const void > *data, size_t datalen) > ret = datablob_parse(datablob, new_p, new_o); > if (ret != Opt_update) { > ret = -EINVAL; > + kfree(new_p); > goto out; > } > /* copy old key values, and reseal with new pcrs */ > -- > To unsubscribe from this list: send the line "unsubscribe git-commits-head" in > the body of a message to [email protected] > More majordomo info at http://vger.kernel.org/majordomo-info.html > > _______________________________________________ > stable mailing list > [email protected] > http://linux.kernel.org/mailman/listinfo/stable _______________________________________________ stable mailing list [email protected] http://linux.kernel.org/mailman/listinfo/stable
