diff options
author | Diego Biurrun <diego@biurrun.de> | 2008-01-10 10:35:37 +0000 |
---|---|---|
committer | Diego Biurrun <diego@biurrun.de> | 2008-01-10 10:35:37 +0000 |
commit | f3635240b77bd838304320df4a2b84a2de94130c (patch) | |
tree | 250751a9847d383e4a75f559eb9d08513feb73ce | |
parent | c33820e52e8829668ef59b7ead6acee09558504f (diff) | |
download | ffmpeg-f3635240b77bd838304320df4a2b84a2de94130c.tar.gz |
Fix a couple of 'return type defaults to int' and 'control reaches end of
non-void function' warnings in test code.
Originally committed as revision 11491 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r-- | libavutil/adler32.c | 1 | ||||
-rw-r--r-- | libavutil/crc.c | 3 | ||||
-rw-r--r-- | libavutil/integer.c | 3 | ||||
-rw-r--r-- | libavutil/mathematics.c | 3 | ||||
-rw-r--r-- | libavutil/md5.c | 4 |
5 files changed, 10 insertions, 4 deletions
diff --git a/libavutil/adler32.c b/libavutil/adler32.c index 76df12054d..148664e532 100644 --- a/libavutil/adler32.c +++ b/libavutil/adler32.c @@ -66,5 +66,6 @@ int main(void){ STOP_TIMER("adler") } av_log(NULL, AV_LOG_DEBUG, "%X == 50E6E508\n", checksum); + return 0; } #endif diff --git a/libavutil/crc.c b/libavutil/crc.c index b715a6558d..1de67a6ad1 100644 --- a/libavutil/crc.c +++ b/libavutil/crc.c @@ -130,7 +130,7 @@ uint32_t av_crc(const AVCRC *ctx, uint32_t crc, const uint8_t *buffer, size_t le #ifdef TEST #undef printf -main(void){ +int main(void){ uint8_t buf[1999]; int i; int p[4][3]={{AV_CRC_32_IEEE_LE, 0xEDB88320, 0x3D5CDD04}, @@ -146,5 +146,6 @@ main(void){ ctx = av_crc_get_table(p[i][0]); printf("crc %08X =%X\n", p[i][1], av_crc(ctx, 0, buf, sizeof(buf))); } + return 0; } #endif diff --git a/libavutil/integer.c b/libavutil/integer.c index 55dde412d4..a7ab5c97fb 100644 --- a/libavutil/integer.c +++ b/libavutil/integer.c @@ -171,7 +171,7 @@ const uint8_t ff_log2_tab[256]={ 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7 }; -main(void){ +int main(void){ int64_t a,b; for(a=7; a<256*256*256; a+=13215){ @@ -192,5 +192,6 @@ main(void){ assert(av_i2int(av_div_i(ai,bi)) == a/b); } } + return 0; } #endif diff --git a/libavutil/mathematics.c b/libavutil/mathematics.c index 71d8ba7b1a..f9c4a68573 100644 --- a/libavutil/mathematics.c +++ b/libavutil/mathematics.c @@ -114,7 +114,7 @@ int64_t av_rescale_q(int64_t a, AVRational bq, AVRational cq){ #ifdef TEST #include "integer.h" #undef printf -main(void){ +int main(void){ int64_t a,b,c,d,e; for(a=7; a<(1LL<<62); a+=a/3+1){ @@ -136,5 +136,6 @@ main(void){ } } } + return 0; } #endif diff --git a/libavutil/md5.c b/libavutil/md5.c index e31b102286..03c09acbe7 100644 --- a/libavutil/md5.c +++ b/libavutil/md5.c @@ -164,7 +164,7 @@ void av_md5_sum(uint8_t *dst, const uint8_t *src, const int len){ #ifdef TEST #include <stdio.h> #undef printf -main(void){ +int main(void){ uint64_t md5val; int i; uint8_t in[1000]; @@ -176,5 +176,7 @@ main(void){ av_md5_sum( (uint8_t*)&md5val, in, 65); printf("%"PRId64"\n", md5val); for(i=0; i<1000; i++) in[i]= i % 127; av_md5_sum( (uint8_t*)&md5val, in, 999); printf("%"PRId64"\n", md5val); + + return 0; } #endif |