Fix clang warning

"a function declaration without a prototype is deprecated in all versions of C"
This commit is contained in:
Erik Ekman 2024-07-15 23:54:25 +02:00
parent 6be47466f2
commit 2c7940cf77
14 changed files with 26 additions and 26 deletions

View File

@ -103,7 +103,7 @@ static long send_query_recvcnt = 0;
static int hostname_maxlen = 0xFF;
void
client_init()
client_init(void)
{
running = 1;
rand_seed = ((unsigned int) rand()) & 0xFFFF;
@ -124,13 +124,13 @@ client_init()
}
void
client_stop()
client_stop(void)
{
running = 0;
}
enum connection
client_get_conn()
client_get_conn(void)
{
return conn;
}
@ -175,7 +175,7 @@ client_set_qtype(char *qtype)
}
char *
client_get_qtype()
client_get_qtype(void)
{
char *c = "UNDEFINED";
@ -225,7 +225,7 @@ client_set_hostname_maxlen(int i)
}
const char *
client_get_raw_addr()
client_get_raw_addr(void)
{
return format_addr(&raw_serv, raw_serv_len);
}

View File

@ -276,7 +276,7 @@ do_pidfile(char *pidfile)
}
void
do_detach()
do_detach(void)
{
#ifndef WINDOWS32
fprintf(stderr, "Detaching from terminal...\n");

View File

@ -20,7 +20,7 @@
static struct fw_query fwq[FW_QUERY_CACHE_SIZE];
static int fwq_ix;
void fw_query_init()
void fw_query_init(void)
{
memset(fwq, 0, sizeof(struct fw_query) * FW_QUERY_CACHE_SIZE);
fwq_ix = 0;

View File

@ -119,7 +119,7 @@ START_TEST(test_base32_blksize)
END_TEST
TCase *
test_base32_create_tests()
test_base32_create_tests(void)
{
TCase *tc;

View File

@ -132,7 +132,7 @@ START_TEST(test_base64_blksize)
END_TEST
TCase *
test_base64_create_tests()
test_base64_create_tests(void)
{
TCase *tc;

View File

@ -281,7 +281,7 @@ START_TEST(test_parse_format_ipv4_mapped_ipv6)
END_TEST
TCase *
test_common_create_tests()
test_common_create_tests(void)
{
TCase *tc;
int sock;

View File

@ -250,7 +250,7 @@ dump_packet(char *buf, size_t len)
}
TCase *
test_dns_create_tests()
test_dns_create_tests(void)
{
TCase *tc;

View File

@ -93,7 +93,7 @@ START_TEST(test_build_hostname)
END_TEST
TCase *
test_encoding_create_tests()
test_encoding_create_tests(void)
{
TCase *tc;

View File

@ -76,7 +76,7 @@ START_TEST(test_fw_query_edge)
END_TEST
TCase *
test_fw_query_create_tests()
test_fw_query_create_tests(void)
{
TCase *tc;

View File

@ -59,7 +59,7 @@ START_TEST(test_login_hash_short)
END_TEST
TCase *
test_login_create_tests()
test_login_create_tests(void)
{
TCase *tc;

View File

@ -270,7 +270,7 @@ END_TEST
TCase *
test_read_create_tests()
test_read_create_tests(void)
{
TCase *tc;

View File

@ -24,7 +24,7 @@
#include "test.h"
int
main()
main(void)
{
SRunner *runner;
Suite *iodine;

View File

@ -18,15 +18,15 @@
#ifndef __TEST_H__
#define __TEST_H__
TCase *test_base32_create_tests();
TCase *test_base64_create_tests();
TCase *test_common_create_tests();
TCase *test_dns_create_tests();
TCase *test_encoding_create_tests();
TCase *test_read_create_tests();
TCase *test_login_create_tests();
TCase *test_user_create_tests();
TCase *test_fw_query_create_tests();
TCase *test_base32_create_tests(void);
TCase *test_base64_create_tests(void);
TCase *test_common_create_tests(void);
TCase *test_dns_create_tests(void);
TCase *test_encoding_create_tests(void);
TCase *test_read_create_tests(void);
TCase *test_login_create_tests(void);
TCase *test_user_create_tests(void);
TCase *test_fw_query_create_tests(void);
char *va_str(const char *, ...);

View File

@ -170,7 +170,7 @@ START_TEST(test_find_available_user_small_net)
END_TEST
TCase *
test_user_create_tests()
test_user_create_tests(void)
{
TCase *tc;