提交 456a8167 编写于 作者: D David Howells 提交者: 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: NDavid Howells <dhowells@redhat.com>
Signed-off-by: NJames Morris <jmorris@namei.org>
上级 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% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册