Commit 456a8167 authored by David Howells's avatar David Howells Committed by James Morris

KEYS: Permit key_serial() to be called with a const key pointer

Permit key_serial() to be called with a const key pointer.
Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
Signed-off-by: default avatarJames Morris <jmorris@namei.org>
parent f6b24579
...@@ -271,7 +271,7 @@ extern int keyring_add_key(struct key *keyring, ...@@ -271,7 +271,7 @@ extern int keyring_add_key(struct key *keyring,
extern struct key *key_lookup(key_serial_t id); extern struct key *key_lookup(key_serial_t id);
static inline key_serial_t key_serial(struct key *key) static inline key_serial_t key_serial(const struct key *key)
{ {
return key ? key->serial : 0; return key ? key->serial : 0;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment