]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
apparmor: Fix aa_label_build() error handling for failed merges
authorJohn Johansen <john.johansen@canonical.com>
Thu, 24 Jan 2019 21:53:05 +0000 (13:53 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 13 Mar 2019 21:04:07 +0000 (14:04 -0700)
commita579fde7bd48e851daec98c892192a47da1ad5ea
treec89b3d2ae61c40862578d522e1a3f54f77494f54
parent94d4062f6193ef617c1e1ef5d757a44445bdb66f
apparmor: Fix aa_label_build() error handling for failed merges

[ Upstream commit d6d478aee003e19ef90321176552a8ad2929a47f ]

aa_label_merge() can return NULL for memory allocations failures
make sure to handle and set the correct error in this case.

Reported-by: Peng Hao <peng.hao2@zte.com.cn>
Signed-off-by: John Johansen <john.johansen@canonical.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
security/apparmor/domain.c