[FFmpeg-cvslog] riff: use av_assert

Michael Niedermayer git at videolan.org
Thu Jun 14 23:56:52 CEST 2012


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Thu Jun 14 23:52:56 2012 +0200| [01a14ce0424a45caa24d4a9103afe26c39a6fd35] | committer: Michael Niedermayer

riff: use av_assert

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=01a14ce0424a45caa24d4a9103afe26c39a6fd35
---

 libavformat/riff.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/libavformat/riff.c b/libavformat/riff.c
index 9859e58..b03257b 100644
--- a/libavformat/riff.c
+++ b/libavformat/riff.c
@@ -25,6 +25,7 @@
 #include "avio_internal.h"
 #include "riff.h"
 #include "libavcodec/bytestream.h"
+#include "libavutil/avassert.h"
 
 /* Note: when encoding, the first matching tag is used, so order is
    important if multiple tags possible for a given codec. */
@@ -706,7 +707,7 @@ void ff_parse_specific_params(AVCodecContext *stream, int *au_rate, int *au_ssiz
 
 void ff_get_guid(AVIOContext *s, ff_asf_guid *g)
 {
-    assert(sizeof(*g) == 16);
+    av_assert0(sizeof(*g) == 16); //compiler will optimize this out
     if (avio_read(s, *g, sizeof(*g)) < (int)sizeof(*g))
         memset(*g, 0, sizeof(*g));
 }



More information about the ffmpeg-cvslog mailing list