Use "void" for empty argument list in declarations

In C, an empty argument list in a declaration means that the function
can accept any arguments. Use "void" instead, it means "no arguments".

C++ treats void and empty list as "no arguments".
This commit is contained in:
Pavel Roskin
2016-12-23 09:52:22 -08:00
parent 15a24ff1c4
commit 6664aac00f
19 changed files with 34 additions and 34 deletions
+4 -4
View File
@@ -37,8 +37,8 @@
#include <errno.h>
/* forward declarations */
int run_echo_test();
int run_tsmf_test();
int run_echo_test(void);
int run_tsmf_test(void);
int
main(int argc, char **argv)
@@ -76,7 +76,7 @@ main(int argc, char **argv)
* @return 0 on success, -1 on failure
*/
int
run_echo_test()
run_echo_test(void)
{
char out_buf[8192];
char in_buf[1700];
@@ -162,7 +162,7 @@ run_echo_test()
}
int
run_tsmf_test()
run_tsmf_test(void)
{
void *channel;