From ff874c87d7479b1d7c853af369778d99e82c13ba Mon Sep 17 00:00:00 2001
From: Tibor Nagy <xnagytibor@gmail.com>
Date: Wed, 20 Feb 2019 19:27:18 +0100
Subject: [PATCH] tests: Fix function signatures

---
 CONTRIBUTING.md            | 18 +++++++++---------
 tests/alloca.c             |  2 +-
 tests/args.c               |  2 +-
 tests/arpainet.c           |  2 +-
 tests/assert.c             |  2 +-
 tests/constructor.c        |  2 +-
 tests/ctype.c              |  2 +-
 tests/destructor.c         |  2 +-
 tests/dirent/main.c        |  2 +-
 tests/dirent/scandir.c     |  2 +-
 tests/error.c              |  2 +-
 tests/fcntl/create.c       |  2 +-
 tests/fcntl/fcntl.c        |  2 +-
 tests/fnmatch.c            |  2 +-
 tests/libgen.c             |  6 +++---
 tests/locale.c             |  2 +-
 tests/math.c               |  2 +-
 tests/netdb/netdb.c        |  2 +-
 tests/pwd.c                |  2 +-
 tests/regex.c              |  2 +-
 tests/resource/getrusage.c |  2 +-
 tests/select.c             |  2 +-
 tests/setjmp.c             |  2 +-
 tests/signal.c             |  2 +-
 tests/stdio/all.c          |  2 +-
 tests/stdio/buffer.c       |  2 +-
 tests/stdio/fgets.c        |  2 +-
 tests/stdio/fputs.c        |  2 +-
 tests/stdio/fread.c        |  2 +-
 tests/stdio/freopen.c      |  2 +-
 tests/stdio/fseek.c        |  2 +-
 tests/stdio/fwrite.c       |  2 +-
 tests/stdio/getc_unget.c   |  2 +-
 tests/stdio/mutex.c        |  2 +-
 tests/stdio/popen.c        |  2 +-
 tests/stdio/printf.c       |  2 +-
 tests/stdio/rename.c       |  2 +-
 tests/stdio/scanf.c        |  2 +-
 tests/stdio/setvbuf.c      |  2 +-
 tests/stdio/sprintf.c      |  2 +-
 tests/stdlib/a64l.c        |  2 +-
 tests/stdlib/alloc.c       |  2 +-
 tests/stdlib/atof.c        |  2 +-
 tests/stdlib/atoi.c        |  2 +-
 tests/stdlib/bsearch.c     |  2 +-
 tests/stdlib/div.c         |  7 +++----
 tests/stdlib/env.c         |  2 +-
 tests/stdlib/mkostemps.c   |  2 +-
 tests/stdlib/mktemp.c      |  2 +-
 tests/stdlib/rand.c        |  2 +-
 tests/stdlib/realpath.c    |  2 +-
 tests/stdlib/strtod.c      |  2 +-
 tests/stdlib/strtol.c      |  2 +-
 tests/stdlib/strtoul.c     |  2 +-
 tests/stdlib/system.c      |  2 +-
 tests/string/mem.c         |  2 +-
 tests/string/strcat.c      |  2 +-
 tests/string/strchr.c      |  2 +-
 tests/string/strcpy.c      |  2 +-
 tests/string/strcspn.c     |  2 +-
 tests/string/strncmp.c     |  2 +-
 tests/string/strpbrk.c     |  2 +-
 tests/string/strrchr.c     |  3 +--
 tests/string/strspn.c      |  2 +-
 tests/string/strstr.c      |  2 +-
 tests/string/strtok.c      |  2 +-
 tests/string/strtok_r.c    |  2 +-
 tests/strings.c            |  2 +-
 tests/sys_utsname/uname.c  |  2 +-
 tests/time/asctime.c       |  2 +-
 tests/time/gettimeofday.c  |  2 +-
 tests/time/gmtime.c        |  2 +-
 tests/time/localtime.c     |  2 +-
 tests/time/macros.c        |  2 +-
 tests/time/mktime.c        |  3 ++-
 tests/time/strftime.c      |  3 ++-
 tests/time/time.c          |  2 +-
 tests/time/times.c         |  2 +-
 tests/unistd/access.c      |  2 +-
 tests/unistd/brk.c         |  2 +-
 tests/unistd/chdir.c       |  2 +-
 tests/unistd/dup.c         |  2 +-
 tests/unistd/exec.c        |  2 +-
 tests/unistd/fchdir.c      |  2 +-
 tests/unistd/fsync.c       |  2 +-
 tests/unistd/ftruncate.c   |  2 +-
 tests/unistd/getcwd.c      |  2 +-
 tests/unistd/gethostname.c |  2 +-
 tests/unistd/getid.c       |  2 +-
 tests/unistd/isatty.c      |  2 +-
 tests/unistd/link.c        |  2 +-
 tests/unistd/pathconf.c    |  2 +-
 tests/unistd/pipe.c        |  4 +---
 tests/unistd/rmdir.c       |  2 +-
 tests/unistd/setid.c       |  5 ++---
 tests/unistd/sleep.c       |  2 +-
 tests/unistd/stat.c        |  2 +-
 tests/unistd/sysconf.c     |  2 +-
 tests/unistd/write.c       |  2 +-
 tests/waitpid.c            |  2 +-
 tests/wchar/mbrtowc.c      |  3 +--
 tests/wchar/mbsrtowcs.c    |  3 +--
 tests/wchar/putwchar.c     |  3 +--
 tests/wchar/wcrtomb.c      |  5 ++---
 104 files changed, 120 insertions(+), 127 deletions(-)

diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index ddeac8444..e1d1a28dc 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -88,14 +88,14 @@ just in case, it'd be a good idea to map inputs to variables.
 #include "string.h"
 #include "stdio.h"
 
-int main() {
-	// Don't do this
-	printf("%d\n", strcspn("Hello", "Hi"));
-
-	// Do this
-	char *first = "Hello";
-	char *second = "Hi";
-	printf("%d\n", strcspn(first, second));
+int main(void) {
+    // Don't do this
+    printf("%d\n", strcspn("Hello", "Hi"));
+
+    // Do this
+    char *first = "Hello";
+    char *second = "Hi";
+    printf("%d\n", strcspn(first, second));
 }
 ```
 
@@ -120,4 +120,4 @@ You can test against verified correct output with `make verify` in the tests
 directory. You will need to manually create the correct output and put it in the
 tests/expected directory. Running any `make` commands in the tests directory
 will ***not*** rebuild relibc, so you'll need to go back to the root directory
-if you need to rebuild relibc.
\ No newline at end of file
+if you need to rebuild relibc.
diff --git a/tests/alloca.c b/tests/alloca.c
index 990bd49b3..3d774c5fc 100644
--- a/tests/alloca.c
+++ b/tests/alloca.c
@@ -2,7 +2,7 @@
 #include <stdio.h>
 #include <string.h>
 
-int main(int argc, char ** argv) {
+int main(void) {
     char *str = (char *) alloca(17);
 
     memset(str, 'A', 16);
diff --git a/tests/args.c b/tests/args.c
index fd9c77970..e05509c40 100644
--- a/tests/args.c
+++ b/tests/args.c
@@ -1,7 +1,7 @@
 #include <string.h>
 #include <unistd.h>
 
-int main(int argc, char ** argv) {
+int main(int argc, char *argv[]) {
     int i;
     for(i = 0; i < argc; i++) {
         write(STDOUT_FILENO, argv[i], strlen(argv[i]));
diff --git a/tests/arpainet.c b/tests/arpainet.c
index c93f3933c..cae9921b5 100644
--- a/tests/arpainet.c
+++ b/tests/arpainet.c
@@ -3,7 +3,7 @@
 #include <string.h>
 #include <stdlib.h>
 
-int main(int argc, char** argv) {
+int main(void) {
     uint32_t hl = 0xBADFACED;
     uint32_t nl = htonl(hl);
     assert(nl == 0xEDACDFBA);
diff --git a/tests/assert.c b/tests/assert.c
index 7f98bbe9c..0ab46cafa 100644
--- a/tests/assert.c
+++ b/tests/assert.c
@@ -2,7 +2,7 @@
 #include <stdlib.h>
 #include <stdio.h>
 
-int main() {
+int main(void) {
     assert(1 == 1);
     assert(1 + 1 == 2);
     puts("yay!");
diff --git a/tests/constructor.c b/tests/constructor.c
index 01f4f9ca3..38fc58cba 100644
--- a/tests/constructor.c
+++ b/tests/constructor.c
@@ -16,6 +16,6 @@ TEST(102)
 TEST(103)
 TEST(104)
 
-int main(int argc, char *argv[]) {
+int main(void) {
     puts("main");
 }
diff --git a/tests/ctype.c b/tests/ctype.c
index 46682640b..40ba65ae4 100644
--- a/tests/ctype.c
+++ b/tests/ctype.c
@@ -293,7 +293,7 @@ size_t num_test_cases = sizeof(test_cases) / sizeof(struct test_case);
         printf("Unexpected result: " #fn "('%c') != %d // Char value: %d\n", tc.c, tc.fn, tc.c); \
     }
 
-int main(int argc, char* argv[]) {
+int main(void) {
     int retval = 0;
 
     for(int i = 0; i < num_test_cases; ++i) {
diff --git a/tests/destructor.c b/tests/destructor.c
index 57b87ff11..40840ccde 100644
--- a/tests/destructor.c
+++ b/tests/destructor.c
@@ -16,6 +16,6 @@ TEST(102)
 TEST(103)
 TEST(104)
 
-int main(int argc, char *argv[]) {
+int main(void) {
     puts("main");
 }
diff --git a/tests/dirent/main.c b/tests/dirent/main.c
index 08cea6929..430626af7 100644
--- a/tests/dirent/main.c
+++ b/tests/dirent/main.c
@@ -2,7 +2,7 @@
 #include <errno.h>
 #include <stdio.h>
 
-int main() {
+int main(void) {
     printf("%lu\n", sizeof(struct dirent));
 
     DIR* dir = opendir("example_dir/");
diff --git a/tests/dirent/scandir.c b/tests/dirent/scandir.c
index 383a6ca0b..2b2ea03c2 100644
--- a/tests/dirent/scandir.c
+++ b/tests/dirent/scandir.c
@@ -7,7 +7,7 @@ int filter(const struct dirent* dirent) {
     return strstr(dirent->d_name, "3") == NULL;
 }
 
-int main() {
+int main(void) {
     struct dirent** array;
     int len = scandir("example_dir/", &array, filter, alphasort);
     if (len < 0) {
diff --git a/tests/error.c b/tests/error.c
index 0b539992d..ac84c343b 100644
--- a/tests/error.c
+++ b/tests/error.c
@@ -3,7 +3,7 @@
 #include <string.h>
 #include <errno.h>
 
-int main(int argc, char** argv) {
+int main(void) {
     chdir("nonexistent");
     printf("errno: %d = %s\n", errno, strerror(errno));
     perror("perror");
diff --git a/tests/fcntl/create.c b/tests/fcntl/create.c
index 864496830..8e70cb6c6 100644
--- a/tests/fcntl/create.c
+++ b/tests/fcntl/create.c
@@ -1,7 +1,7 @@
 #include <fcntl.h>
 #include <unistd.h>
 
-int main(int argc, char ** argv) {
+int main(void) {
     int fd = creat("create.out", 0755);
     if (fd >= 0) {
         write(fd, "Hello World!\n", 13);
diff --git a/tests/fcntl/fcntl.c b/tests/fcntl/fcntl.c
index 4ce261d18..474e163f5 100644
--- a/tests/fcntl/fcntl.c
+++ b/tests/fcntl/fcntl.c
@@ -2,7 +2,7 @@
 #include <stdio.h>
 #include <unistd.h>
 
-int main() {
+int main(void) {
     //Lose our fd and pull it again
     creat("fcntl.out", 0777);
     int newfd = open("fcntl.out", 0);
diff --git a/tests/fnmatch.c b/tests/fnmatch.c
index 4d10a642e..9fa673f53 100644
--- a/tests/fnmatch.c
+++ b/tests/fnmatch.c
@@ -9,7 +9,7 @@ void test(char* pattern, char* input, int flags) {
     }
 }
 
-int main() {
+int main(void) {
     puts("Should succeed:");
     test("*World", "Hello World", 0);
     test("*World", "World", 0);
diff --git a/tests/libgen.c b/tests/libgen.c
index f38f70f0f..fd79f5b9d 100644
--- a/tests/libgen.c
+++ b/tests/libgen.c
@@ -18,7 +18,7 @@ char * get_mutable_string(char *str) {
   return copy;
 }
 
-void test_basename() {
+void test_basename(void) {
   test_case test_cases[] =
   { {"/usr/lib", "lib"},
     {"//usr//lib//", "lib"},
@@ -44,7 +44,7 @@ void test_basename() {
   return;
 }
 
-void test_dirname() {
+void test_dirname(void) {
   test_case test_cases[] =
   { {"/usr/lib", "/usr"},
     {"//usr//lib//", "//usr"},
@@ -73,7 +73,7 @@ void test_dirname() {
   return;
 }
 
-int main() {
+int main(void) {
   printf("Testing libgen.h\n");
   test_basename();
   test_dirname();
diff --git a/tests/locale.c b/tests/locale.c
index 9358bc555..dde3364da 100644
--- a/tests/locale.c
+++ b/tests/locale.c
@@ -2,7 +2,7 @@
 #include <stdio.h>
 #include <string.h>
 
-int main() {
+int main(void) {
     // TODO: Implement locale properly and test it here
     char* val = setlocale(LC_ALL, NULL);
     if (strcmp(val, "C") == 0) {
diff --git a/tests/math.c b/tests/math.c
index fb53fa243..014529f46 100644
--- a/tests/math.c
+++ b/tests/math.c
@@ -1,7 +1,7 @@
 #include <math.h>
 #include <stdio.h>
 
-int main(int argc, char ** argv) {
+int main(void) {
     double pi = 3.14;
     float c = cos(pi);
     printf("cos(%f) = %f\n", pi, c);
diff --git a/tests/netdb/netdb.c b/tests/netdb/netdb.c
index 9bbbf3e28..d81f08d63 100644
--- a/tests/netdb/netdb.c
+++ b/tests/netdb/netdb.c
@@ -225,6 +225,6 @@ do_test (void)
   return (error_count != 0);
 }
 
-int main() {
+int main(void) {
     do_test();
 }
diff --git a/tests/pwd.c b/tests/pwd.c
index 52b351167..77087425e 100644
--- a/tests/pwd.c
+++ b/tests/pwd.c
@@ -13,7 +13,7 @@ void print(struct passwd *pwd) {
     printf("pw_shell: %s\n", pwd->pw_shell);
 }
 
-int main() {
+int main(void) {
     puts("--- Checking getpwuid ---");
     errno = 0;
     struct passwd *pwd = getpwuid(0);
diff --git a/tests/regex.c b/tests/regex.c
index cd692f89b..b74a0f2ce 100644
--- a/tests/regex.c
+++ b/tests/regex.c
@@ -1,7 +1,7 @@
 #include <regex.h>
 #include <stdio.h>
 
-int main() {
+int main(void) {
     regex_t regex;
     char error_buf[256];
 
diff --git a/tests/resource/getrusage.c b/tests/resource/getrusage.c
index a84433503..e04a62391 100644
--- a/tests/resource/getrusage.c
+++ b/tests/resource/getrusage.c
@@ -6,7 +6,7 @@ void ptimeval(struct timeval* val) {
     printf("{ tv_sec: %ld, tv_usec: %ld }\n", val->tv_sec, val->tv_usec);
 }
 
-int main() {
+int main(void) {
     struct rusage r_usage;
     if (getrusage(RUSAGE_SELF, &r_usage) < 0) {
         perror("getrusage");
diff --git a/tests/select.c b/tests/select.c
index ba053a1e0..596a589a8 100644
--- a/tests/select.c
+++ b/tests/select.c
@@ -3,7 +3,7 @@
 #include <sys/select.h>
 #include <unistd.h>
 
-int main() {
+int main(void) {
     int fd = open("select.c", 0, 0);
 
     fd_set read;
diff --git a/tests/setjmp.c b/tests/setjmp.c
index c45390bf4..fe117e4de 100644
--- a/tests/setjmp.c
+++ b/tests/setjmp.c
@@ -1,7 +1,7 @@
 #include <stdio.h>
 #include <setjmp.h>
 
-int main() {
+int main(void) {
     jmp_buf buf;
     if (setjmp(buf)) {
         puts("hi from jump");
diff --git a/tests/signal.c b/tests/signal.c
index 7f4178561..aa9a563e0 100644
--- a/tests/signal.c
+++ b/tests/signal.c
@@ -7,7 +7,7 @@ void handler(int sig) {
     puts("Signal handler called!");
 }
 
-int main() {
+int main(void) {
     if (signal(SIGUSR1, &handler) == SIG_ERR) {
         puts("Signal error!");
         printf("%d\n", errno);
diff --git a/tests/stdio/all.c b/tests/stdio/all.c
index 118f46541..c049e3eb0 100644
--- a/tests/stdio/all.c
+++ b/tests/stdio/all.c
@@ -1,7 +1,7 @@
 #include <stdio.h>
 #include <stdlib.h>
 
-int main(int argc, char ** argv) {
+int main(void) {
 	FILE *f = fopen("stdio/stdio.in", "r");
 	printf("%c\n", fgetc(f));
 	ungetc('H', f);
diff --git a/tests/stdio/buffer.c b/tests/stdio/buffer.c
index c5d55944b..50b236f14 100644
--- a/tests/stdio/buffer.c
+++ b/tests/stdio/buffer.c
@@ -1,6 +1,6 @@
 #include <stdio.h>
 
-int main() {
+int main(void) {
     // Tests what used to be a bug with buffering
     fwrite("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", 1, 999, stdout);
     fwrite("Test\n", 1, 5, stdout);
diff --git a/tests/stdio/fgets.c b/tests/stdio/fgets.c
index c89e491ae..404002a8b 100644
--- a/tests/stdio/fgets.c
+++ b/tests/stdio/fgets.c
@@ -1,6 +1,6 @@
 #include <stdio.h>
 
-int main() {
+int main(void) {
     //FILE *f = fopen("/etc/ssl/certs/ca-certificates.crt", "r");
     FILE *f = fopen("stdio/stdio.in", "r");
     char line[256];
diff --git a/tests/stdio/fputs.c b/tests/stdio/fputs.c
index 34ac5f361..2ce599203 100644
--- a/tests/stdio/fputs.c
+++ b/tests/stdio/fputs.c
@@ -2,7 +2,7 @@
 #include <stdlib.h>
 #include <errno.h>
 
-int main(int argc, char ** argv) {
+int main(void) {
 	FILE *f = fopen("stdio/fputs.out", "w");
 	char *in = "Hello World!";
 	fputs(in, f); // calls fwrite, helpers::fwritex, internal::to_write and internal::stdio_write
diff --git a/tests/stdio/fread.c b/tests/stdio/fread.c
index 40b6f69e5..f87e9172b 100644
--- a/tests/stdio/fread.c
+++ b/tests/stdio/fread.c
@@ -1,7 +1,7 @@
 #include <errno.h>
 #include <stdio.h>
 
-int main(int argc, char *argv[]) {
+int main(void) {
     FILE *fp = fopen("stdio/fread.in", "rb");
 
     char buf[33] = { 0 };
diff --git a/tests/stdio/freopen.c b/tests/stdio/freopen.c
index 7bf3b64f2..3189b7e64 100644
--- a/tests/stdio/freopen.c
+++ b/tests/stdio/freopen.c
@@ -1,6 +1,6 @@
 #include <stdio.h>
 
-int main(int argc, char ** argv) {
+int main(void) {
 	freopen("stdio/stdio.in", "r", stdin);
 	char in[6];
 	fgets(in, 6, stdin);
diff --git a/tests/stdio/fseek.c b/tests/stdio/fseek.c
index 84f544d2a..eed59eca0 100644
--- a/tests/stdio/fseek.c
+++ b/tests/stdio/fseek.c
@@ -1,6 +1,6 @@
 #include <stdio.h>
 
-int main() {
+int main(void) {
 	FILE *f = fopen("stdio/stdio.in", "r");
     if (fseek(f, 14, SEEK_CUR) < 0) {
         puts("fseek error");
diff --git a/tests/stdio/fwrite.c b/tests/stdio/fwrite.c
index 85da11905..37df8a75c 100644
--- a/tests/stdio/fwrite.c
+++ b/tests/stdio/fwrite.c
@@ -2,7 +2,7 @@
 #include <stdlib.h>
 #include <errno.h>
 
-int main(int argc, char ** argv) {
+int main(void) {
 	FILE *f = fopen("stdio/fwrite.out", "w");
 	const char ptr[] = "Hello World!";
 
diff --git a/tests/stdio/getc_unget.c b/tests/stdio/getc_unget.c
index f8008534f..257170a04 100644
--- a/tests/stdio/getc_unget.c
+++ b/tests/stdio/getc_unget.c
@@ -1,6 +1,6 @@
 #include <stdio.h>
 
-int main(int argc, char ** argv) {
+int main(void) {
 	ungetc('h', stdin);
 	char c;
 	if ((c = getchar()) == 'h') {
diff --git a/tests/stdio/mutex.c b/tests/stdio/mutex.c
index 032ced27e..04f7b386c 100644
--- a/tests/stdio/mutex.c
+++ b/tests/stdio/mutex.c
@@ -1,6 +1,6 @@
 #include <stdio.h>
 
-int main() {
+int main(void) {
     FILE* f = fopen("stdio/stdio.in", "r");
 
     flockfile(f);
diff --git a/tests/stdio/popen.c b/tests/stdio/popen.c
index 9550b0ef2..364b3753b 100644
--- a/tests/stdio/popen.c
+++ b/tests/stdio/popen.c
@@ -1,6 +1,6 @@
 #include <stdio.h>
 
-int main(int argc, char **argv) {
+int main(void) {
     FILE *fp;
     int status;
     char path[256];
diff --git a/tests/stdio/printf.c b/tests/stdio/printf.c
index 3ef0c9b22..833b39c84 100644
--- a/tests/stdio/printf.c
+++ b/tests/stdio/printf.c
@@ -1,6 +1,6 @@
 #include <stdio.h>
 
-int main(int argc, char ** argv) {
+int main(void) {
     int sofar = 0;
     int len = printf(
         "percent: %%\nstring: %s\nchar: %c\nchar: %c\nint: %d\n%nuint: %u\nhex: %x\nHEX: %X\nstring: %s\n",
diff --git a/tests/stdio/rename.c b/tests/stdio/rename.c
index 189ba2277..537b2dc6a 100644
--- a/tests/stdio/rename.c
+++ b/tests/stdio/rename.c
@@ -8,7 +8,7 @@ static char newpath[] = "new-name.out";
 static char str[] = "Hello, World!";
 int str_len = 13;
 
-int main() {
+int main(void) {
     char buf[14];
     buf[13] = 0x00;
     int fd = creat(oldpath, 0777);
diff --git a/tests/stdio/scanf.c b/tests/stdio/scanf.c
index 3f6a23663..a19daaf3b 100644
--- a/tests/stdio/scanf.c
+++ b/tests/stdio/scanf.c
@@ -25,7 +25,7 @@ void test(char* fmt_in, char* input, struct params *p, ...) {
     );
 }
 
-int main(int argc, char ** argv) {
+int main(void) {
     struct params p = { .c = 'a' };
 
     test("%hhd %d", "12 345", &p, &p.sa, &p.ia);
diff --git a/tests/stdio/setvbuf.c b/tests/stdio/setvbuf.c
index 62a13aeeb..46191f53c 100644
--- a/tests/stdio/setvbuf.c
+++ b/tests/stdio/setvbuf.c
@@ -1,7 +1,7 @@
 #include <stdio.h>
 #include <stdlib.h>
 
-int main(int argc, char ** argv) {
+int main(void) {
 	setvbuf(stdout, 0, _IONBF, 0);
 	FILE *f = fopen("stdio/stdio.in", "r");
 	setvbuf(f, 0, _IONBF, 0);
diff --git a/tests/stdio/sprintf.c b/tests/stdio/sprintf.c
index 7e42245bc..3205473e3 100644
--- a/tests/stdio/sprintf.c
+++ b/tests/stdio/sprintf.c
@@ -1,7 +1,7 @@
 #include <stdio.h>
 #include <string.h>
 
-int main(int argc, char ** argv) {
+int main(void) {
     char buffer[72];
 
     int ret = sprintf(
diff --git a/tests/stdlib/a64l.c b/tests/stdlib/a64l.c
index 8036d9e3f..14d44a9f8 100644
--- a/tests/stdlib/a64l.c
+++ b/tests/stdlib/a64l.c
@@ -1,7 +1,7 @@
 #include <stdlib.h>
 #include <stdio.h>
 
-int main(int argc, char* argv[]) {
+int main(void) {
     char * s = "azAZ9."; // test boundaries
     long l = a64l(s);
     if (l != 194301926) {
diff --git a/tests/stdlib/alloc.c b/tests/stdlib/alloc.c
index bfb867340..85d6c9c07 100644
--- a/tests/stdlib/alloc.c
+++ b/tests/stdlib/alloc.c
@@ -2,7 +2,7 @@
 #include <stdio.h>
 #include <stdlib.h>
 
-int main(int argc, char ** argv) {
+int main(void) {
     char * ptr = (char *)malloc(256);
     printf("malloc %p\n", ptr);
     int i;
diff --git a/tests/stdlib/atof.c b/tests/stdlib/atof.c
index 1bfb9d0e2..37f8d1129 100644
--- a/tests/stdlib/atof.c
+++ b/tests/stdlib/atof.c
@@ -1,7 +1,7 @@
 #include <stdlib.h>
 #include <stdio.h>
 
-int main(int argc, char* argv[]) {
+int main(void) {
     double d = atof("-3.14");
     printf("%f\n", d);
     return 0;
diff --git a/tests/stdlib/atoi.c b/tests/stdlib/atoi.c
index e9af8da95..8ce33962f 100644
--- a/tests/stdlib/atoi.c
+++ b/tests/stdlib/atoi.c
@@ -1,7 +1,7 @@
 #include <stdlib.h>
 #include <stdio.h>
 
-int main(int argc, char* argv[]) {
+int main(void) {
     printf("%d\n", atoi("         -42"));
     printf("%d\n", atoi(" +555"));
     printf("%d\n", atoi("   1234567890    "));
diff --git a/tests/stdlib/bsearch.c b/tests/stdlib/bsearch.c
index c8e43c612..9ccd1a7d4 100644
--- a/tests/stdlib/bsearch.c
+++ b/tests/stdlib/bsearch.c
@@ -19,7 +19,7 @@ int int_cmp(const void* a, const void* b) {
 
 
 
-int main(int argc, char* argv[]) {
+int main(void) {
   int x = 0;
   int y = 1024;
 
diff --git a/tests/stdlib/div.c b/tests/stdlib/div.c
index 22acb9176..7752fb5d1 100644
--- a/tests/stdlib/div.c
+++ b/tests/stdlib/div.c
@@ -3,10 +3,9 @@
          volatile long double ld;
          volatile unsigned long long ll;
          lldiv_t mydivt;
-int
-main ()
-{
-char* tmp;
+
+int main(void) {
+         char* tmp;
          f = strtof("gnu", &tmp);
          ld = strtold("gnu", &tmp);
          ll = strtoll("gnu", &tmp, 10);
diff --git a/tests/stdlib/env.c b/tests/stdlib/env.c
index e0a821c83..684e78bed 100644
--- a/tests/stdlib/env.c
+++ b/tests/stdlib/env.c
@@ -2,7 +2,7 @@
 #include <stdlib.h>
 #include <string.h>
 
-int main() {
+int main(void) {
     //puts(getenv("SHELL"));
     //puts(getenv("CC"));
 
diff --git a/tests/stdlib/mkostemps.c b/tests/stdlib/mkostemps.c
index 2ada5d1f4..c3547f49c 100644
--- a/tests/stdlib/mkostemps.c
+++ b/tests/stdlib/mkostemps.c
@@ -2,7 +2,7 @@
 #include <stdio.h>
 #include <string.h>
 
-int main(int argc, char** argv) {
+int main(void) {
     char* file_name = (char*) calloc(18, sizeof(char));
     strcpy(file_name, "tempXXXXXX.suffix");
     int fd = mkostemps(file_name, 7, 0);
diff --git a/tests/stdlib/mktemp.c b/tests/stdlib/mktemp.c
index eaafe8348..e2394f636 100644
--- a/tests/stdlib/mktemp.c
+++ b/tests/stdlib/mktemp.c
@@ -2,7 +2,7 @@
 #include <stdio.h>
 #include <string.h>
 
-int main(int argc, char** argv) {
+int main(void) {
     char* string = (char*) calloc(20, sizeof(char));
     strcpy(string, "tempXXXXXX");
     mktemp(string);
diff --git a/tests/stdlib/rand.c b/tests/stdlib/rand.c
index 484b09906..f3883c3fd 100644
--- a/tests/stdlib/rand.c
+++ b/tests/stdlib/rand.c
@@ -1,7 +1,7 @@
 #include <stdlib.h>
 #include <stdio.h>
 
-int main(int argc, char** argv) {
+int main(void) {
     printf("%d\n", rand());
     srand(259);
     printf("%d\n", rand());
diff --git a/tests/stdlib/realpath.c b/tests/stdlib/realpath.c
index c6a679a4d..918874ee2 100644
--- a/tests/stdlib/realpath.c
+++ b/tests/stdlib/realpath.c
@@ -4,7 +4,7 @@
 #include <stdlib.h>
 #include <string.h>
 
-int main() {
+int main(void) {
     char* path = realpath("stdlib/realpath.c", NULL);
     if (!path) {
         perror("realpath");
diff --git a/tests/stdlib/strtod.c b/tests/stdlib/strtod.c
index 21a728050..ae88af4db 100644
--- a/tests/stdlib/strtod.c
+++ b/tests/stdlib/strtod.c
@@ -1,7 +1,7 @@
 #include <stdlib.h>
 #include <stdio.h>
 
-int main() {
+int main(void) {
     char* endptr = 0;
     double d;
 
diff --git a/tests/stdlib/strtol.c b/tests/stdlib/strtol.c
index c088e144b..e98964ad5 100644
--- a/tests/stdlib/strtol.c
+++ b/tests/stdlib/strtol.c
@@ -2,7 +2,7 @@
 #include <stdlib.h>
 #include <stdio.h>
 
-int main(int argc, char* argv[]) {
+int main(void) {
     printf("%ld\n", strtol("         -42", NULL, 0));
     printf("%ld\n", strtol(" +555", NULL, 0));
     printf("%ld\n", strtol("   1234567890    ", NULL, 0));
diff --git a/tests/stdlib/strtoul.c b/tests/stdlib/strtoul.c
index 4431a720d..2e7f36867 100644
--- a/tests/stdlib/strtoul.c
+++ b/tests/stdlib/strtoul.c
@@ -2,7 +2,7 @@
 #include <stdlib.h>
 #include <stdio.h>
 
-int main(int argc, char* argv[]) {
+int main(void) {
     printf("%ld\n", strtoul("         -42", NULL, 0));
     printf("%ld\n", strtoul(" +555", NULL, 0));
     printf("%ld\n", strtoul("   1234567890    ", NULL, 0));
diff --git a/tests/stdlib/system.c b/tests/stdlib/system.c
index 8c4cda187..9acc8d6b3 100644
--- a/tests/stdlib/system.c
+++ b/tests/stdlib/system.c
@@ -1,6 +1,6 @@
 #include <stdlib.h>
 
-int main(int argc, char ** argv) {
+int main(void) {
     system("echo test of system");
     return 0;
 }
diff --git a/tests/string/mem.c b/tests/string/mem.c
index 121a8f5f3..43424b816 100644
--- a/tests/string/mem.c
+++ b/tests/string/mem.c
@@ -2,7 +2,7 @@
 #include <stdlib.h>
 #include <string.h>
 
-int main(int argc, char ** argv) {
+int main(void) {
     puts("# mem #");
     char arr[100];
     memset(arr, 0, 100); // Compiler builtin, should work
diff --git a/tests/string/strcat.c b/tests/string/strcat.c
index 6913c5575..2ccc93272 100644
--- a/tests/string/strcat.c
+++ b/tests/string/strcat.c
@@ -1,7 +1,7 @@
 #include <string.h>
 #include <stdio.h>
 
-int main(int argc, char* argv[]) {
+int main(void) {
     char dest1[12] = "hello";
 	  printf("%s\n", strcat(dest1, " world")); // should be hello world
 
diff --git a/tests/string/strchr.c b/tests/string/strchr.c
index 202737faa..7ef4452ee 100644
--- a/tests/string/strchr.c
+++ b/tests/string/strchr.c
@@ -1,7 +1,7 @@
 #include <string.h>
 #include <stdio.h>
 
-int main(int argc, char* argv[]) {
+int main(void) {
 	printf("%s\n", strchr("hello", 'e')); // should be ello
 	printf("%s\n", strchr("world", 'l')); // should be ld
 	printf("%i\n", strchr("world", 0) == NULL); // should be 1
diff --git a/tests/string/strcpy.c b/tests/string/strcpy.c
index f0c7d7925..69159d738 100644
--- a/tests/string/strcpy.c
+++ b/tests/string/strcpy.c
@@ -1,7 +1,7 @@
 #include <stdio.h>
 #include <string.h>
 
-int main() {
+int main(void) {
     char dst[20];
 
     strcpy(dst, "strcpy works!");
diff --git a/tests/string/strcspn.c b/tests/string/strcspn.c
index 859d88043..b9a81c8b2 100644
--- a/tests/string/strcspn.c
+++ b/tests/string/strcspn.c
@@ -1,7 +1,7 @@
 #include <string.h>
 #include <stdio.h>
 
-int main(int argc, char* argv[]) {
+int main(void) {
 	char *world = "world";
 	printf("%ld\n", strcspn("hello", world)); // should be 2
 	printf("%ld\n", strcspn("banana", world)); // should be 6
diff --git a/tests/string/strncmp.c b/tests/string/strncmp.c
index efb2bea97..122a1ca64 100644
--- a/tests/string/strncmp.c
+++ b/tests/string/strncmp.c
@@ -1,7 +1,7 @@
 #include <string.h>
 #include <stdio.h>
 
-int main(int argc, char* argv[]) {
+int main(void) {
     printf("%d\n", strncmp("a", "aa", 2));
     printf("%d\n", strncmp("a", "aä", 2));
     printf("%d\n", strncmp("\xFF", "\xFE", 2));
diff --git a/tests/string/strpbrk.c b/tests/string/strpbrk.c
index dc0ebf7c5..248ade939 100644
--- a/tests/string/strpbrk.c
+++ b/tests/string/strpbrk.c
@@ -1,7 +1,7 @@
 #include <string.h>
 #include <stdio.h>
 
-int main(int argc, char* argv[]) {
+int main(void) {
     char* source = "The quick drawn fix jumps over the lazy bug";
 
     // should be "The quick drawn fix jumps over the lazy bug"
diff --git a/tests/string/strrchr.c b/tests/string/strrchr.c
index 7edc98040..d999cacc4 100644
--- a/tests/string/strrchr.c
+++ b/tests/string/strrchr.c
@@ -1,8 +1,7 @@
 #include <string.h>
 #include <stdio.h>
 
-
-int main(int argc, char* argv[]) {
+int main(void) {
   char s0[] = "hello, world";
   char* ptr = strrchr(s0, 'l');
   if (ptr != &s0[10]) {
diff --git a/tests/string/strspn.c b/tests/string/strspn.c
index 52431a70f..30caaaaf9 100644
--- a/tests/string/strspn.c
+++ b/tests/string/strspn.c
@@ -1,7 +1,7 @@
 #include <string.h>
 #include <stdio.h>
 
-int main(int argc, char* argv[]) {
+int main(void) {
 	char *hello = "hello";
 	char *world = "world";
 	char *banana = "banana";
diff --git a/tests/string/strstr.c b/tests/string/strstr.c
index cc23f070f..90c8f3497 100644
--- a/tests/string/strstr.c
+++ b/tests/string/strstr.c
@@ -1,7 +1,7 @@
 #include <string.h>
 #include <stdio.h>
 
-int main(int argc, char* argv[]) {
+int main(void) {
     printf("%s\n", strstr("In relibc we trust", "rust"));
     printf("%s\n", strstr("In relibc we trust", "libc"));
     printf("%s\n", strstr("In relibc we trust", "bugs"));
diff --git a/tests/string/strtok.c b/tests/string/strtok.c
index 18436d9f7..6333f5c3b 100644
--- a/tests/string/strtok.c
+++ b/tests/string/strtok.c
@@ -1,7 +1,7 @@
 #include <string.h>
 #include <stdio.h>
 
-int main(int argc, char* argv[]) {
+int main(void) {
     char source[] = "I'd just like to interject for a moment.  What you're referring to as Linux, "
                     "is in fact, GNU/Linux, or as I've recently taken to calling it, GNU plus Linux.\n";
 
diff --git a/tests/string/strtok_r.c b/tests/string/strtok_r.c
index 6b3f50142..9238f0a18 100644
--- a/tests/string/strtok_r.c
+++ b/tests/string/strtok_r.c
@@ -1,7 +1,7 @@
 #include <string.h>
 #include <stdio.h>
 
-int main(int argc, char* argv[]) {
+int main(void) {
     char source[] = "I'd just like to interject for a moment.  What you're referring to as Linux, "
                     "is in fact, GNU/Linux, or as I've recently taken to calling it, GNU plus Linux.\n";
     char* sp;
diff --git a/tests/strings.c b/tests/strings.c
index fefb631a6..11cdb48fe 100644
--- a/tests/strings.c
+++ b/tests/strings.c
@@ -3,7 +3,7 @@
 #include <stdio.h>
 #include <strings.h>
 
-int main() {
+int main(void) {
     assert(!bcmp("hello", "hehe", 2));
     assert(bcmp("hello", "haha", 2));
 
diff --git a/tests/sys_utsname/uname.c b/tests/sys_utsname/uname.c
index 05ad03401..8e094df41 100644
--- a/tests/sys_utsname/uname.c
+++ b/tests/sys_utsname/uname.c
@@ -1,7 +1,7 @@
 #include <stdio.h>
 #include <sys/utsname.h>
 
-int main() {
+int main(void) {
     struct utsname system_info;
 
     int result = uname(&system_info);
diff --git a/tests/time/asctime.c b/tests/time/asctime.c
index a2a3db03f..a76b032b2 100644
--- a/tests/time/asctime.c
+++ b/tests/time/asctime.c
@@ -3,7 +3,7 @@
 #include <stdlib.h>
 #include <string.h>
 
-int main(int argc, char** argv) {
+int main(void) {
     time_t a = 0;
     struct tm *time_info = gmtime(&a);
 
diff --git a/tests/time/gettimeofday.c b/tests/time/gettimeofday.c
index 7cd71d9ae..a17e2aedf 100644
--- a/tests/time/gettimeofday.c
+++ b/tests/time/gettimeofday.c
@@ -1,7 +1,7 @@
 #include <sys/time.h>
 #include <stdio.h>
 
-int main() {
+int main(void) {
     struct timeval tv;
     gettimeofday(&tv, NULL);
     printf("%ld: %ld\n", tv.tv_sec, tv.tv_usec);
diff --git a/tests/time/gmtime.c b/tests/time/gmtime.c
index 836822db3..f8be76adc 100644
--- a/tests/time/gmtime.c
+++ b/tests/time/gmtime.c
@@ -3,7 +3,7 @@
 #include <stdlib.h>
 #include <string.h>
 
-int main(int argc, char** argv) {
+int main(void) {
     time_t a = 0;
     struct tm expected = { .tm_sec = 0, .tm_min = 0, .tm_hour = 0, .tm_mday = 1, .tm_year = 70,
                     .tm_wday = 4, .tm_yday = 0, .tm_isdst = 0, .tm_gmtoff = 0, .tm_zone = "UTC" };
diff --git a/tests/time/localtime.c b/tests/time/localtime.c
index 3792531b9..5f96b3ea2 100644
--- a/tests/time/localtime.c
+++ b/tests/time/localtime.c
@@ -1,7 +1,7 @@
 #include <stdio.h>
 #include <time.h>
 
-int main() {
+int main(void) {
     int day = 60 * 60 * 24;
     time_t inputs[] = { -(day * 33), -day, -1, -500, 0, 1, 1531454950 };
     for (int i = 0; i < (sizeof(inputs) / sizeof(time_t)); i += 1) {
diff --git a/tests/time/macros.c b/tests/time/macros.c
index b33f78b75..737dab831 100644
--- a/tests/time/macros.c
+++ b/tests/time/macros.c
@@ -1,7 +1,7 @@
 #include <assert.h>
 #include <sys/time.h>
 
-int main() {
+int main(void) {
     struct timeval x = { .tv_usec = 15 };
     struct timeval y = { 0 };
     struct timeval z = { 0 };
diff --git a/tests/time/mktime.c b/tests/time/mktime.c
index c99102f67..94b96eb8c 100644
--- a/tests/time/mktime.c
+++ b/tests/time/mktime.c
@@ -18,7 +18,8 @@ int check(time_t input) {
     }
     return 0;
 }
-int main() {
+
+int main(void) {
     struct tm t = { 0 };
 
     t.tm_year = 71;
diff --git a/tests/time/strftime.c b/tests/time/strftime.c
index 56ecc6f9e..99da578bf 100644
--- a/tests/time/strftime.c
+++ b/tests/time/strftime.c
@@ -8,7 +8,8 @@ void print(time_t timestamp, char* fmt) {
     printf("%zu: %s\n", n, out);
     free(out);
 }
-int main() {
+
+int main(void) {
     print(1531808742, "%a %A %b %B");
     print(1531808742, "The %Cst century");
     print(1531808742, "%I:%M:%S %p");
diff --git a/tests/time/time.c b/tests/time/time.c
index 3dc120b27..3fe2fc232 100644
--- a/tests/time/time.c
+++ b/tests/time/time.c
@@ -1,7 +1,7 @@
 #include <time.h>
 #include <stdio.h>
 
-int main(int argc, char** argv) {
+int main(void) {
     struct timespec tm = {0, 0};
 
     int cgt = clock_gettime(CLOCK_REALTIME, &tm);
diff --git a/tests/time/times.c b/tests/time/times.c
index 975aae2dd..91829b4ca 100644
--- a/tests/time/times.c
+++ b/tests/time/times.c
@@ -2,7 +2,7 @@
 #include <sys/times.h>
 #include <unistd.h>
 
-int main() {
+int main(void) {
     struct tms tms;
     printf("return: %ld\n", times(&tms));
 
diff --git a/tests/unistd/access.c b/tests/unistd/access.c
index 9491aa5f5..2ba3d0184 100644
--- a/tests/unistd/access.c
+++ b/tests/unistd/access.c
@@ -1,7 +1,7 @@
 #include <stdio.h>
 #include <unistd.h>
 
-int main() {
+int main(void) {
     if (access("example_dir/1-never-gonna-give-you-up", R_OK | W_OK)) {
         perror("access");
         return 1;
diff --git a/tests/unistd/brk.c b/tests/unistd/brk.c
index 138b0080f..60d3ad0d1 100644
--- a/tests/unistd/brk.c
+++ b/tests/unistd/brk.c
@@ -1,7 +1,7 @@
 #include <unistd.h>
 #include <stdio.h>
 
-int main(int argc, char** argv) {
+int main(void) {
     int status = brk((void*)100);
     printf("brk exited with status code %d\n", status);
     return 0;
diff --git a/tests/unistd/chdir.c b/tests/unistd/chdir.c
index be0e29018..f0cd849af 100644
--- a/tests/unistd/chdir.c
+++ b/tests/unistd/chdir.c
@@ -2,7 +2,7 @@
 #include <stdio.h>
 #include <stdlib.h>
 
-int main(int argc, char** argv) {
+int main(void) {
     char* cwd1 = malloc(4096*sizeof(char));//(char*) calloc(4096 + 1, sizeof(char));
     getcwd(cwd1, 4096);
     printf("initial cwd: %s\n", cwd1);
diff --git a/tests/unistd/dup.c b/tests/unistd/dup.c
index 54bbb159b..10a56ea88 100644
--- a/tests/unistd/dup.c
+++ b/tests/unistd/dup.c
@@ -2,7 +2,7 @@
 #include <fcntl.h>
 #include <stdio.h>
 
-int main(int argc, char** argv) {
+int main(void) {
     creat("dup.out", 0777);
     int fd1 = open("dup.out", 0);
     int fd2 = dup(fd1);
diff --git a/tests/unistd/exec.c b/tests/unistd/exec.c
index 732ed00ae..fd603471e 100644
--- a/tests/unistd/exec.c
+++ b/tests/unistd/exec.c
@@ -1,7 +1,7 @@
 #include <unistd.h>
 #include <stdio.h>
 
-int main(int argc, char** argv) {
+int main(void) {
     char* args[] = {"sh", "-c", "echo 'exec works :D'", NULL};
     execv("/bin/sh", args);
     perror("execv");
diff --git a/tests/unistd/fchdir.c b/tests/unistd/fchdir.c
index e89c5ef59..07256cf28 100644
--- a/tests/unistd/fchdir.c
+++ b/tests/unistd/fchdir.c
@@ -2,7 +2,7 @@
 #include <fcntl.h>
 #include <stdio.h>
 
-int main (int argc, char** argv) {
+int main(void) {
     int fd = open("..", 0, 0);
     int status;
     status = fchdir(fd);
diff --git a/tests/unistd/fsync.c b/tests/unistd/fsync.c
index d9f42bd23..b7d2f76d5 100644
--- a/tests/unistd/fsync.c
+++ b/tests/unistd/fsync.c
@@ -2,7 +2,7 @@
 #include <fcntl.h>
 #include <stdio.h>
 
-int main (int argc, char** argv) {
+int main(void) {
     int fd = open(".", 0, 0);
     int status;
     status = fsync(fd);
diff --git a/tests/unistd/ftruncate.c b/tests/unistd/ftruncate.c
index 67f39f4c4..05634015c 100644
--- a/tests/unistd/ftruncate.c
+++ b/tests/unistd/ftruncate.c
@@ -2,7 +2,7 @@
 #include <fcntl.h>
 #include <stdio.h>
 
-int main (int argc, char** argv) {
+int main(void) {
     int fd = creat("ftruncate.out", 0777);
     int status;
     status = ftruncate(fd, 100);
diff --git a/tests/unistd/getcwd.c b/tests/unistd/getcwd.c
index 0d8e5f108..fd5bd60cc 100644
--- a/tests/unistd/getcwd.c
+++ b/tests/unistd/getcwd.c
@@ -4,7 +4,7 @@
 #include <string.h>
 #include <unistd.h>
 
-int main() {
+int main(void) {
     char first[PATH_MAX];
     getcwd(first, PATH_MAX);
     puts(first);
diff --git a/tests/unistd/gethostname.c b/tests/unistd/gethostname.c
index 02a0b7a7d..85119c32f 100644
--- a/tests/unistd/gethostname.c
+++ b/tests/unistd/gethostname.c
@@ -2,7 +2,7 @@
 #include <stdio.h>
 #include <unistd.h>
 
-int main() {
+int main(void) {
     char* hostname = malloc(256);
     if (gethostname(hostname, 256) == 0) {
         printf("Hostname: %s\n", hostname);
diff --git a/tests/unistd/getid.c b/tests/unistd/getid.c
index 774ffea26..b6a8507dc 100644
--- a/tests/unistd/getid.c
+++ b/tests/unistd/getid.c
@@ -1,7 +1,7 @@
 #include <unistd.h>
 #include <stdio.h>
 
-int main(int argc, char** argv) {
+int main(void) {
     gid_t egid = getegid();
     uid_t euid = geteuid();
     gid_t gid = getgid();
diff --git a/tests/unistd/isatty.c b/tests/unistd/isatty.c
index 9647282aa..33855fbaf 100644
--- a/tests/unistd/isatty.c
+++ b/tests/unistd/isatty.c
@@ -1,7 +1,7 @@
 #include <stdio.h>
 #include <unistd.h>
 
-int main() {
+int main(void) {
     // 1 is stdout
     if (isatty(1)) {
         puts("'Tis a tty :D");
diff --git a/tests/unistd/link.c b/tests/unistd/link.c
index a39286106..264c2dda5 100644
--- a/tests/unistd/link.c
+++ b/tests/unistd/link.c
@@ -3,7 +3,7 @@
 #include <sys/stat.h>
 #include <unistd.h>
 
-int main(int argc, char** argv) {
+int main(void) {
     printf("%ld\n", sizeof(struct stat));
 
     struct stat buf;
diff --git a/tests/unistd/pathconf.c b/tests/unistd/pathconf.c
index f943ec56e..77cb7d546 100644
--- a/tests/unistd/pathconf.c
+++ b/tests/unistd/pathconf.c
@@ -7,7 +7,7 @@
 	printf("%s (%d): %ld (%d)\n", #N, _PC_ ## N, fpathconf(0, _PC_ ## N), errno); \
 }
 
-int main(){
+int main(void) {
 	PC(LINK_MAX);
 	PC(MAX_CANON);
 	PC(MAX_INPUT);
diff --git a/tests/unistd/pipe.c b/tests/unistd/pipe.c
index 8f0fc71e5..2e1edf2c9 100644
--- a/tests/unistd/pipe.c
+++ b/tests/unistd/pipe.c
@@ -3,9 +3,7 @@
 #include <string.h>
 #include <unistd.h>
 
-int main()
-{
-
+int main(void) {
     int pid, pip[2];
     char instring[20];
     char * outstring = "Hello World!";
diff --git a/tests/unistd/rmdir.c b/tests/unistd/rmdir.c
index 97aa50fe1..11a8bd646 100644
--- a/tests/unistd/rmdir.c
+++ b/tests/unistd/rmdir.c
@@ -2,7 +2,7 @@
 #include <sys/stat.h>
 #include <stdio.h>
 
-int main(int argc, char** argv) {
+int main(void) {
     mkdir("foo", 0);
     int status = rmdir("foo");
     printf("rmdir exited with status code %d\n", status);
diff --git a/tests/unistd/setid.c b/tests/unistd/setid.c
index cf6abc6c6..78b01dda2 100644
--- a/tests/unistd/setid.c
+++ b/tests/unistd/setid.c
@@ -6,8 +6,7 @@
 #include <unistd.h>
 #include <stdlib.h>
 
-int main( void )
-  {
+int main(void) {
     if( setpgid( getpid(), 0 ) == -1 ) {
         perror( "setpgid" );
     }
@@ -24,4 +23,4 @@ int main( void )
     }
     printf("%d has euid %d and uid %d\n", getpid(), geteuid(), getuid());
     return 0;
-  }
+}
diff --git a/tests/unistd/sleep.c b/tests/unistd/sleep.c
index cf395a783..df69754dd 100644
--- a/tests/unistd/sleep.c
+++ b/tests/unistd/sleep.c
@@ -2,7 +2,7 @@
 #include <unistd.h>
 #include <stdio.h>
 
-int main(int argc, char** argv) {
+int main(void) {
     sleep(2);
     perror("sleep");
     usleep(1000);
diff --git a/tests/unistd/stat.c b/tests/unistd/stat.c
index 5fd178530..a0775bc53 100644
--- a/tests/unistd/stat.c
+++ b/tests/unistd/stat.c
@@ -3,7 +3,7 @@
 #include <sys/stat.h>
 #include <unistd.h>
 
-int main() {
+int main(void) {
     printf("%ld\n", sizeof(struct stat));
 
     struct stat buf;
diff --git a/tests/unistd/sysconf.c b/tests/unistd/sysconf.c
index aa4bf4882..6e53ee3c4 100644
--- a/tests/unistd/sysconf.c
+++ b/tests/unistd/sysconf.c
@@ -7,7 +7,7 @@
 	printf("%s (%d): %ld (%d)\n", #N, _SC_ ## N, sysconf(_SC_ ## N), errno); \
 }
 
-int main(){
+int main(void) {
 	SC(ARG_MAX);
 	SC(CHILD_MAX);
 	SC(CLK_TCK);
diff --git a/tests/unistd/write.c b/tests/unistd/write.c
index 5102aca42..bfc52a920 100644
--- a/tests/unistd/write.c
+++ b/tests/unistd/write.c
@@ -1,6 +1,6 @@
 #include <unistd.h>
 
-int main(int argc, char ** argv) {
+int main(void) {
     write(STDOUT_FILENO, "Hello World!\n", 13);
     return 0;
 }
diff --git a/tests/waitpid.c b/tests/waitpid.c
index c350e33c6..0a52eaa45 100644
--- a/tests/waitpid.c
+++ b/tests/waitpid.c
@@ -2,7 +2,7 @@
 #include <unistd.h>
 #include <stdlib.h>
 
-int main(int argc, char** argv) {
+int main(void) {
     pid_t pid = fork();
     if (pid == 0) {
         // child
diff --git a/tests/wchar/mbrtowc.c b/tests/wchar/mbrtowc.c
index 293926d7e..f05f70313 100644
--- a/tests/wchar/mbrtowc.c
+++ b/tests/wchar/mbrtowc.c
@@ -2,8 +2,7 @@
 #include <string.h>
 #include <wchar.h>
  
-int main(void)
-{
+int main(void) {
     mbstate_t state;
     memset(&state, 0, sizeof state);
     char in[] = u8"z\u00df\u6c34\U0001F34C"; // or u8"zß水🍌"
diff --git a/tests/wchar/mbsrtowcs.c b/tests/wchar/mbsrtowcs.c
index 070cabc3c..15dff0b7e 100644
--- a/tests/wchar/mbsrtowcs.c
+++ b/tests/wchar/mbsrtowcs.c
@@ -17,8 +17,7 @@ void print_as_wide(const char* mbstr)
     //wprintf(L"The wide string: %ls \n", &wstr[0]);
 }
 
-int main()
-{
+int main(void) {
     const char* mbstr = u8"z\u00df\u6c34\U0001f34c"; // or u8"zß水🍌"
     print_as_wide(mbstr);
 }
diff --git a/tests/wchar/putwchar.c b/tests/wchar/putwchar.c
index 067c0a410..a777854a5 100644
--- a/tests/wchar/putwchar.c
+++ b/tests/wchar/putwchar.c
@@ -3,8 +3,7 @@
 #include <wchar.h>
 #include <stdlib.h>
 
-int main(void)
-{
+int main(void) {
     wchar_t *wcs = L"zß水🍌";
 
     int i;
diff --git a/tests/wchar/wcrtomb.c b/tests/wchar/wcrtomb.c
index 4bf5dc357..233496ed3 100644
--- a/tests/wchar/wcrtomb.c
+++ b/tests/wchar/wcrtomb.c
@@ -2,9 +2,8 @@
 #include <stdio.h>  
 #include <wchar.h> 
 #include <stdlib.h>
-  
-int main( void )  
-{  
+
+int main(void) {
     mbstate_t state;
     memset(&state, 0, sizeof state);
     wchar_t in[] = L"zß水🍌"; // or "z\u00df\u6c34\U0001F34C"
-- 
GitLab