[devel] [PATCH 3/8] set.c: fixup self-test functions declaration

Kirill A. Shutsemov kirill на shutemov.name
Вт Ноя 16 15:56:37 UTC 2010


From: Kirill A. Shutemov <kirill на shutemov.name>

Signed-off-by: Kirill A. Shutemov <kirill на shutemov.name>
---
 lib/set.c |   17 ++++++++++-------
 1 files changed, 10 insertions(+), 7 deletions(-)

diff --git a/lib/set.c b/lib/set.c
index 1b516c7..03c8149 100644
--- a/lib/set.c
+++ b/lib/set.c
@@ -192,7 +192,8 @@ int decode_base62(const char *base62, char *bitv)
 }
 
 #ifdef SELF_TEST
-void test_base62()
+static
+void test_base62(void)
 {
     const char rnd_bitv[] = {
 	1, 0, 0, 1, 0, 0, 1, 1, 1, 1, 1, 0, 1, 0, 0, 1,
@@ -360,7 +361,8 @@ int decode_golomb(int bitc, const char *bitv, int Mshift, unsigned *v)
 }
 
 #ifdef SELF_TEST
-void test_golomb()
+static
+void test_golomb(void)
 {
     const unsigned rnd_v[] = {
 	/* do re mi fa sol la si */
@@ -430,7 +432,8 @@ void decode_delta(int c, unsigned *v)
 }
 
 #ifdef SELF_TEST
-void test_delta()
+static
+void test_delta(void)
 {
     unsigned v[] = {
 	1, 3, 7, 0
@@ -494,7 +497,7 @@ int uniqv(int c, unsigned *v)
 
 #ifdef SELF_TEST
 static
-void test_aux()
+void test_aux(void)
 {
     unsigned v[] = { 2, 3, 1, 2, 7, 6, 5 };
     int c = sizeof v / sizeof *v;
@@ -625,7 +628,7 @@ int downsample_set(int c, unsigned *v, int bpp)
 
 #ifdef SELF_TEST
 static
-void test_set()
+void test_set(void)
 {
     unsigned rnd_v[] = {
 	0x020a, 0x07e5, 0x3305, 0x35f5,
@@ -842,7 +845,7 @@ const char *set_fini(struct set *set, int bpp)
 
 #ifdef SELF_TEST
 static
-void test_api()
+void test_api(void)
 {
     struct set *set1 = set_new();
     set_add(set1, "mama");
@@ -889,7 +892,7 @@ void test_api()
 #endif
 
 #ifdef SELF_TEST
-int main()
+int main(int argc, char **argv)
 {
     test_base62();
     test_golomb();
-- 
1.7.3.2



Подробная информация о списке рассылки Devel