diff options
author | YueHaibing <yuehaibing@huawei.com> | 2019-06-11 15:48:15 +0200 |
---|---|---|
committer | James Morris <jamorris@linux.microsoft.com> | 2019-06-11 23:05:16 +0200 |
commit | d1c5947ec6789b7d72cd7365f4e37ec326dbd9b6 (patch) | |
tree | 1f924eb0be14ce4b964e34470399d0e8f221e06e /security/commoncap.c | |
parent | Linux 5.1 (diff) | |
download | linux-d1c5947ec6789b7d72cd7365f4e37ec326dbd9b6.tar.xz linux-d1c5947ec6789b7d72cd7365f4e37ec326dbd9b6.zip |
security: Make capability_hooks static
Fix sparse warning:
security/commoncap.c:1347:27: warning:
symbol 'capability_hooks' was not declared. Should it be static?
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Signed-off-by: James Morris <jamorris@linux.microsoft.com>
Diffstat (limited to 'security/commoncap.c')
-rw-r--r-- | security/commoncap.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/security/commoncap.c b/security/commoncap.c index c477fb673701..afd9679ca866 100644 --- a/security/commoncap.c +++ b/security/commoncap.c @@ -1344,7 +1344,7 @@ int cap_mmap_file(struct file *file, unsigned long reqprot, #ifdef CONFIG_SECURITY -struct security_hook_list capability_hooks[] __lsm_ro_after_init = { +static struct security_hook_list capability_hooks[] __lsm_ro_after_init = { LSM_HOOK_INIT(capable, cap_capable), LSM_HOOK_INIT(settime, cap_settime), LSM_HOOK_INIT(ptrace_access_check, cap_ptrace_access_check), |