public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH -next] lib/ubsan.c: Mark type_check_kinds with static keyword
@ 2020-12-10 12:17 Zou Wei
  2020-12-11 18:17 ` Kees Cook
  0 siblings, 1 reply; 2+ messages in thread
From: Zou Wei @ 2020-12-10 12:17 UTC (permalink / raw)
  To: keescook, akpm, arnd; +Cc: linux-kernel, Zou Wei

Fix the following sparse warning:

lib/ubsan.c:20:12: warning: symbol 'type_check_kinds' was not declared. Should it be static?

Signed-off-by: Zou Wei <zou_wei@huawei.com>
---
 lib/ubsan.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/ubsan.c b/lib/ubsan.c
index cb9af3f6..3cfe902 100644
--- a/lib/ubsan.c
+++ b/lib/ubsan.c
@@ -17,7 +17,7 @@
 
 #include "ubsan.h"
 
-const char *type_check_kinds[] = {
+static const char *type_check_kinds[] = {
 	"load of",
 	"store to",
 	"reference binding to",
-- 
2.6.2


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH -next] lib/ubsan.c: Mark type_check_kinds with static keyword
  2020-12-10 12:17 [PATCH -next] lib/ubsan.c: Mark type_check_kinds with static keyword Zou Wei
@ 2020-12-11 18:17 ` Kees Cook
  0 siblings, 0 replies; 2+ messages in thread
From: Kees Cook @ 2020-12-11 18:17 UTC (permalink / raw)
  To: Zou Wei; +Cc: akpm, arnd, linux-kernel

On Thu, Dec 10, 2020 at 08:17:18PM +0800, Zou Wei wrote:
> Fix the following sparse warning:
> 
> lib/ubsan.c:20:12: warning: symbol 'type_check_kinds' was not declared. Should it be static?
> 
> Signed-off-by: Zou Wei <zou_wei@huawei.com>

Reviewed-by: Kees Cook <keescook@chromium.org>

-- 
Kees Cook

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-12-11 19:54 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-12-10 12:17 [PATCH -next] lib/ubsan.c: Mark type_check_kinds with static keyword Zou Wei
2020-12-11 18:17 ` Kees Cook

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox