Mercurial > libavformat.hg
diff nut.c @ 5902:dbbcecb1a0dd libavformat
Fix NUT (de)muxer warnings:
CC libavformat/nutdec.o
libavformat/nutdec.c: In function ¡Æread_seek¡Ç:
libavformat/nutdec.c:862: warning: passing argument 3 of ¡Æav_tree_find¡Ç from incompatible pointer type
./libavutil/tree.h:44: note: expected ¡Æint (*)(void *, const void *)¡Ç but argument is of type ¡Æint (*)(struct Syncpoint *, struct Syncpoint *)¡Ç
libavformat/nutdec.c:871: warning: passing argument 3 of ¡Æav_tree_find¡Ç from incompatible pointer type
./libavutil/tree.h:44: note: expected ¡Æint (*)(void *, const void *)¡Ç but argument is of type ¡Æint (*)(struct Syncpoint *, struct Syncpoint *)¡Ç
libavformat/nutdec.c:879: warning: passing argument 3 of ¡Æav_tree_find¡Ç from incompatible pointer type
./libavutil/tree.h:44: note: expected ¡Æint (*)(void *, const void *)¡Ç but argument is of type ¡Æint (*)(struct Syncpoint *, struct Syncpoint *)¡Ç
CC libavformat/nutenc.o
libavformat/nutenc.c: In function ¡Æwrite_packet¡Ç:
libavformat/nutenc.c:680: warning: passing argument 3 of ¡Æav_tree_find¡Ç from incompatible pointer type
./libavutil/tree.h:44: note: expected ¡Æint (*)(void *, const void *)¡Ç but argument is of type ¡Æint (*)(struct Syncpoint *, struct Syncpoint *)¡Ç
author | vitor |
---|---|
date | Sun, 28 Mar 2010 09:59:58 +0000 |
parents | 01b33a7f96ee |
children | c7b98381ec2d |
line wrap: on
line diff
--- a/nut.c Sun Mar 28 08:48:45 2010 +0000 +++ b/nut.c Sun Mar 28 09:59:58 2010 +0000 @@ -47,11 +47,11 @@ return ((lsb - delta)&mask) + delta; } -int ff_nut_sp_pos_cmp(Syncpoint *a, Syncpoint *b){ +int ff_nut_sp_pos_cmp(const Syncpoint *a, const Syncpoint *b){ return ((a->pos - b->pos) >> 32) - ((b->pos - a->pos) >> 32); } -int ff_nut_sp_pts_cmp(Syncpoint *a, Syncpoint *b){ +int ff_nut_sp_pts_cmp(const Syncpoint *a, const Syncpoint *b){ return ((a->ts - b->ts) >> 32) - ((b->ts - a->ts) >> 32); } @@ -62,7 +62,7 @@ sp->pos= pos; sp->back_ptr= back_ptr; sp->ts= ts; - av_tree_insert(&nut->syncpoints, sp, ff_nut_sp_pos_cmp, &node); + av_tree_insert(&nut->syncpoints, sp, (void *) ff_nut_sp_pos_cmp, &node); if(node){ av_free(sp); av_free(node);