[FFmpeg-cvslog] avutil/softfloat: Fix dependence on signed overflow in av_normalize1_sf()

Michael Niedermayer git at videolan.org
Thu Oct 9 17:09:17 CEST 2014


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Thu Oct  9 16:37:26 2014 +0200| [44198a728d15b780def29b30e7d0244e3bc1c5c6] | committer: Michael Niedermayer

avutil/softfloat: Fix dependence on signed overflow in av_normalize1_sf()

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

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

 libavutil/softfloat.h |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavutil/softfloat.h b/libavutil/softfloat.h
index 97e09ea..04c79bf 100644
--- a/libavutil/softfloat.h
+++ b/libavutil/softfloat.h
@@ -57,7 +57,7 @@ static av_const SoftFloat av_normalize_sf(SoftFloat a){
 
 static inline av_const SoftFloat av_normalize1_sf(SoftFloat a){
 #if 1
-    if(a.mant + 0x40000000 < 0){
+    if((int32_t)(a.mant + 0x40000000U) < 0){
         a.exp++;
         a.mant>>=1;
     }



More information about the ffmpeg-cvslog mailing list