[<prev] [next>] [day] [month] [year] [list]
Message-Id: <20230611113210.182652-1-trix@redhat.com>
Date: Sun, 11 Jun 2023 07:32:10 -0400
From: Tom Rix <trix@...hat.com>
To: dhowells@...hat.com, jarkko@...nel.org, paul@...l-moore.com,
jmorris@...ei.org, serge@...lyn.com
Cc: keyrings@...r.kernel.org, linux-security-module@...r.kernel.org,
linux-kernel@...r.kernel.org, Tom Rix <trix@...hat.com>
Subject: [PATCH] sysctl: set variable key_sysctls storage-class-specifier to static
smatch reports
security/keys/sysctl.c:12:18: warning: symbol
'key_sysctls' was not declared. Should it be static?
This variable is only used in its defining file, so it should be static.
Signed-off-by: Tom Rix <trix@...hat.com>
---
security/keys/sysctl.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/security/keys/sysctl.c b/security/keys/sysctl.c
index b72b82bb20c6..b348e1679d5d 100644
--- a/security/keys/sysctl.c
+++ b/security/keys/sysctl.c
@@ -9,7 +9,7 @@
#include <linux/sysctl.h>
#include "internal.h"
-struct ctl_table key_sysctls[] = {
+static struct ctl_table key_sysctls[] = {
{
.procname = "maxkeys",
.data = &key_quota_maxkeys,
--
2.27.0
Powered by blists - more mailing lists