> 
> +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);
> +}
> +
> 


--
To unsubscribe from this list: send the line "unsubscribe 
linux-security-module" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to