[FFmpeg-cvslog] dvdsubenc: switch to av_assert

Michael Niedermayer git at videolan.org
Sat Jul 28 01:47:11 CEST 2012


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Sat Jul 28 01:18:04 2012 +0200| [0fa352623d2322f99221e6e58d48fce9637054ee] | committer: Michael Niedermayer

dvdsubenc: switch to av_assert

we use av_assert0() because the previous code unconditionally
enabled the assert.

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

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

 libavcodec/dvdsubenc.c |    5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/libavcodec/dvdsubenc.c b/libavcodec/dvdsubenc.c
index c7b6054..543fe61 100644
--- a/libavcodec/dvdsubenc.c
+++ b/libavcodec/dvdsubenc.c
@@ -20,9 +20,8 @@
  */
 #include "avcodec.h"
 #include "bytestream.h"
+#include "libavutil/avassert.h"
 
-#undef NDEBUG
-#include <assert.h>
 
 // ncnt is the nibble counter
 #define PUTNIBBLE(val)\
@@ -53,7 +52,7 @@ static void dvd_encode_rle(uint8_t **pq,
                 if (bitmap[x+len] != color)
                     break;
             color = cmap[color];
-            assert(color < 4);
+            av_assert0(color < 4);
             if (len < 0x04) {
                 PUTNIBBLE((len << 2)|color);
             } else if (len < 0x10) {



More information about the ffmpeg-cvslog mailing list