diff options
author | Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com> | 2016-11-13 22:52:02 +0300 |
---|---|---|
committer | Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com> | 2016-11-15 00:57:07 +0300 |
commit | 0edd569466eb45b134690b9f4efbb57eda86f58d (patch) | |
tree | 54e2f6138f2021d2f5c3eca345ebb3b287e0293f /libavutil/softfloat.h | |
parent | d0d6902444ea10c963e2dc040bebdefdca7746eb (diff) |
softfloat: handle -INT_MAX correctly
This is similar to commit 9ac61e73d0843ec4b83f4e3d47eded73234e406e.
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Diffstat (limited to 'libavutil/softfloat.h')
-rw-r--r-- | libavutil/softfloat.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavutil/softfloat.h b/libavutil/softfloat.h index a3b2238585..48d0d59fd4 100644 --- a/libavutil/softfloat.h +++ b/libavutil/softfloat.h @@ -175,7 +175,7 @@ static inline av_const SoftFloat av_sub_sf(SoftFloat a, SoftFloat b){ */ static inline av_const SoftFloat av_int2sf(int v, int frac_bits){ int exp_offset = 0; - if(v == INT_MIN){ + if(v <= INT_MIN + 1){ exp_offset = 1; v>>=1; } |