Commit e374e772 authored by Michael Niedermayer's avatar Michael Niedermayer

avutil/libm: fix fminf() emulation build failure due to undefined FFMIN

Found-by: 's avatarJames Almer <jamrial@gmail.com>
Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 049b20b2
......@@ -86,7 +86,9 @@ static av_always_inline float cbrtf(float x)
#undef fminf
static av_always_inline av_const float fminf(float x, float y)
{
return FFMIN(x, y);
//Note, the NaN special case is needed for C spec compliance, it should be
//optimized away if the users compiler is configured to assume no NaN
return x > y ? y : (x == x ? x : y);
}
#endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment