From: "Hillf Danton" <hillf.zj@alibaba-inc.com>
To: "'Lukasz Pawelczyk'" <l.pawelczyk@samsung.com>
Cc: "Andy Lutomirski" <luto@amacapital.net>,
"Kees Cook" <keescook@chromium.org>,
"linux-kernel" <linux-kernel@vger.kernel.org>,
<linux-security-module@vger.kernel.org>
Subject: Re: [PATCH v4 09/11] smack: namespace groundwork
Date: Thu, 15 Oct 2015 15:38:56 +0800 [thread overview]
Message-ID: <01a101d1071c$8ce631b0$a6b29510$@alibaba-inc.com> (raw)
In-Reply-To: <019801d1071b$2c124000$8436c000$@alibaba-inc.com>
>
> +static inline void smack_userns_free(struct user_namespace *ns)
> +{
> + struct smack_ns *snsp = ns->security;
> + struct smack_known *skp;
> + struct smack_known_ns *sknp, *n;
> +
> + list_for_each_entry_safe(sknp, n, &snsp->smk_mapped, smk_list_ns) {
> + skp = sknp->smk_unmapped;
> +
> + mutex_lock(&skp->smk_mapped_lock);
> + list_del_rcu(&sknp->smk_list_known);
> + if (sknp->smk_allocated)
> + kfree(sknp->smk_mapped);
> + kfree(sknp);
sknp is released,
> + mutex_unlock(&skp->smk_mapped_lock);
> +
> + list_del(&sknp->smk_list_ns);
but it is used again! typo?
> + }
> +
> + kfree(snsp);
> +}
> +
>
next parent reply other threads:[~2015-10-15 7:46 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <019801d1071b$2c124000$8436c000$@alibaba-inc.com>
2015-10-15 7:38 ` Hillf Danton [this message]
2015-10-15 12:41 ` Lukasz Pawelczyk
2015-10-15 12:53 ` Lukasz Pawelczyk
2015-10-16 3:04 ` Hillf Danton
2015-10-16 10:13 ` Lukasz Pawelczyk
2015-10-14 12:41 [PATCH v4 00/11] Smack namespace Lukasz Pawelczyk
2015-10-14 12:42 ` [PATCH v4 09/11] smack: namespace groundwork Lukasz Pawelczyk
2015-10-29 22:51 ` Casey Schaufler
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='01a101d1071c$8ce631b0$a6b29510$@alibaba-inc.com' \
--to=hillf.zj@alibaba-inc.com \
--cc=keescook@chromium.org \
--cc=l.pawelczyk@samsung.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-security-module@vger.kernel.org \
--cc=luto@amacapital.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome