[FFmpeg-cvslog] libavutil/mathematics: use av_assert()

Michael Niedermayer git at videolan.org
Wed Jun 6 20:05:11 CEST 2012


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Wed Jun  6 20:00:35 2012 +0200| [2f23a8ab17a55e52da502132ad109b6d8a719bf5] | committer: Michael Niedermayer

libavutil/mathematics: use av_assert()

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

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

 libavutil/mathematics.c |    8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/libavutil/mathematics.c b/libavutil/mathematics.c
index 2adefb7..2e6a5fa 100644
--- a/libavutil/mathematics.c
+++ b/libavutil/mathematics.c
@@ -23,11 +23,11 @@
  * miscellaneous math routines and tables
  */
 
-#include <assert.h>
 #include <stdint.h>
 #include <limits.h>
 #include "mathematics.h"
 #include "libavutil/common.h"
+#include "avassert.h"
 
 const uint8_t ff_sqrt_tab[256]={
   0, 16, 23, 28, 32, 36, 40, 43, 46, 48, 51, 54, 56, 58, 60, 62, 64, 66, 68, 70, 72, 74, 76, 77, 79, 80, 82, 84, 85, 87, 88, 90,
@@ -77,9 +77,9 @@ int64_t av_gcd(int64_t a, int64_t b){
 
 int64_t av_rescale_rnd(int64_t a, int64_t b, int64_t c, enum AVRounding rnd){
     int64_t r=0;
-    assert(c > 0);
-    assert(b >=0);
-    assert((unsigned)rnd<=5 && rnd!=4);
+    av_assert2(c > 0);
+    av_assert2(b >=0);
+    av_assert2((unsigned)rnd<=5 && rnd!=4);
 
     if(a<0 && a != INT64_MIN) return -av_rescale_rnd(-a, b, c, rnd ^ ((rnd>>1)&1));
 



More information about the ffmpeg-cvslog mailing list