提交 27d63798 编写于 作者: A Andi Kleen 提交者: Linus Torvalds

Fix install_process_keyring error handling

Fix an incorrect error check that returns 1 for error instead of the
expected error code.
Signed-off-by: NAndi Kleen <ak@linux.intel.com>
Signed-off-by: NDavid Howells <dhowells@redhat.com>
Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
上级 765aaafe
......@@ -207,7 +207,7 @@ static int install_process_keyring(void)
ret = install_process_keyring_to_cred(new);
if (ret < 0) {
abort_creds(new);
return ret != -EEXIST ?: 0;
return ret != -EEXIST ? ret : 0;
}
return commit_creds(new);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册