Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1273697
| From | James Morris <jmorris@namei.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 2/2] keys, trusted: seal with a policy |
| Date | 2015-11-20 03:40 +0100 |
| Message-ID | <qwJMe-13l-11@gated-at.bofh.it> (permalink) |
| References | <qvRiO-7og-9@gated-at.bofh.it> <qvRiO-7og-7@gated-at.bofh.it> <qvYNk-3Of-15@gated-at.bofh.it> <qw52p-86c-5@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Wed, 18 Nov 2015, Jarkko Sakkinen wrote: > On Wed, Nov 18, 2015 at 11:21:01AM +1100, James Morris wrote: > > On Tue, 17 Nov 2015, Jarkko Sakkinen wrote: > > > > > } > > > break; > > > + case Opt_policydigest: > > > + if (!tpm2 || > > > + strlen(args[0].from) != (2 * opt->digest_len)) > > > + return -EINVAL; > > > + kfree(opt->policydigest); > > > + opt->policydigest = kzalloc(opt->digest_len, > > > + GFP_KERNEL); > > > > Is it correct to kfree opt->policydigest here before allocating it? > > I think so. The same option might be encountered multiple times. This would surely signify an error? -- James Morris <jmorris@namei.org> -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH 2/2] keys, trusted: seal with a policy Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com> - 2015-11-17 17:30 +0100
Re: [PATCH 2/2] keys, trusted: seal with a policy James Morris <jmorris@namei.org> - 2015-11-18 01:30 +0100
Re: [PATCH 2/2] keys, trusted: seal with a policy Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com> - 2015-11-18 08:10 +0100
Re: [PATCH 2/2] keys, trusted: seal with a policy James Morris <jmorris@namei.org> - 2015-11-20 03:40 +0100
RE: [tpmdd-devel] [PATCH 2/2] keys, trusted: seal with a policy "Fuchs, Andreas" <andreas.fuchs@sit.fraunhofer.de> - 2015-11-19 12:10 +0100
Re: [tpmdd-devel] [PATCH 2/2] keys, trusted: seal with a policy Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com> - 2015-11-20 16:00 +0100
Re: [PATCH 2/2] keys, trusted: seal with a policy Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com> - 2015-11-21 20:00 +0100
Re: [PATCH 2/2] keys, trusted: seal with a policy Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com> - 2015-11-23 16:00 +0100
csiph-web