summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortb <>2022-02-09 07:48:15 +0000
committertb <>2022-02-09 07:48:15 +0000
commitc4d44cc10c18e9c8ea39e5baa19d51f58af7f3ff (patch)
tree9d7d7af1530cdc73a4a6de84c753420278bedf3d
parent652dcc4768178318a02265fe5fe2c2c80a9b3de2 (diff)
downloadopenbsd-c4d44cc10c18e9c8ea39e5baa19d51f58af7f3ff.tar.gz
openbsd-c4d44cc10c18e9c8ea39e5baa19d51f58af7f3ff.tar.bz2
openbsd-c4d44cc10c18e9c8ea39e5baa19d51f58af7f3ff.zip
silence "function declaration isn't a prototype" warning by changing
int foo() to int foo(void)
-rw-r--r--src/regress/lib/libc/explicit_bzero/explicit_bzero.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/regress/lib/libc/explicit_bzero/explicit_bzero.c b/src/regress/lib/libc/explicit_bzero/explicit_bzero.c
index 9c0e917829..65d7b04813 100644
--- a/src/regress/lib/libc/explicit_bzero/explicit_bzero.c
+++ b/src/regress/lib/libc/explicit_bzero/explicit_bzero.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: explicit_bzero.c,v 1.7 2021/03/27 11:17:58 bcook Exp $ */ 1/* $OpenBSD: explicit_bzero.c,v 1.8 2022/02/09 07:48:15 tb Exp $ */
2/* 2/*
3 * Copyright (c) 2014 Google Inc. 3 * Copyright (c) 2014 Google Inc.
4 * 4 *
@@ -139,7 +139,7 @@ count_secrets(const char *buf)
139} 139}
140 140
141static char * 141static char *
142test_without_bzero() 142test_without_bzero(void)
143{ 143{
144 char buf[SECRETBYTES]; 144 char buf[SECRETBYTES];
145 assert_on_stack(); 145 assert_on_stack();
@@ -150,7 +150,7 @@ test_without_bzero()
150} 150}
151 151
152static char * 152static char *
153test_with_bzero() 153test_with_bzero(void)
154{ 154{
155 char buf[SECRETBYTES]; 155 char buf[SECRETBYTES];
156 assert_on_stack(); 156 assert_on_stack();
@@ -161,14 +161,14 @@ test_with_bzero()
161 return (res); 161 return (res);
162} 162}
163 163
164static void 164static void
165do_test_without_bzero(int signo) 165do_test_without_bzero(int signo)
166{ 166{
167 char *buf = test_without_bzero(); 167 char *buf = test_without_bzero();
168 ASSERT_GE(count_secrets(buf), 1); 168 ASSERT_GE(count_secrets(buf), 1);
169} 169}
170 170
171static void 171static void
172do_test_with_bzero(int signo) 172do_test_with_bzero(int signo)
173{ 173{
174 char *buf = test_with_bzero(); 174 char *buf = test_with_bzero();
@@ -176,7 +176,7 @@ do_test_with_bzero(int signo)
176} 176}
177 177
178int 178int
179main() 179main(void)
180{ 180{
181 setup_stack(); 181 setup_stack();
182 182