summaryrefslogtreecommitdiffstats
path: root/security
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2016-02-01 12:53:14 -0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2016-02-01 12:53:14 -0800
commit6e9131cc43a672003a75483d9b9db5c51015ae5f (patch)
tree23deb539a695272dc9f003b4ab094037ccc10f31 /security
parentafc5ab096581e1ad6e7e7d1533a6bbb1d2b12455 (diff)
parent36f90b0a2ddd60823fe193a85e60ff1906c2a9b3 (diff)
downloadop-kernel-dev-6e9131cc43a672003a75483d9b9db5c51015ae5f.zip
op-kernel-dev-6e9131cc43a672003a75483d9b9db5c51015ae5f.tar.gz
Merge 4.5-rc2 into tty-next
We want the tty/serial fixes in here as well to make merges easier. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'security')
-rw-r--r--security/keys/key.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/security/keys/key.c b/security/keys/key.c
index 07a8731..09ef276 100644
--- a/security/keys/key.c
+++ b/security/keys/key.c
@@ -430,7 +430,8 @@ static int __key_instantiate_and_link(struct key *key,
/* and link it into the destination keyring */
if (keyring) {
- set_bit(KEY_FLAG_KEEP, &key->flags);
+ if (test_bit(KEY_FLAG_KEEP, &keyring->flags))
+ set_bit(KEY_FLAG_KEEP, &key->flags);
__key_link(key, _edit);
}
OpenPOWER on IntegriCloud