Commit 9e3b3c9b authored by Alex Henrie's avatar Alex Henrie Committed by Alexandre Julliard

msvcrt: Set errno in _logb(f) if x is 0.

parent f9e995de
......@@ -142,6 +142,7 @@ INT CDECL MSVCRT__isnanf( float num )
float CDECL MSVCRT__logbf( float num )
{
if (!finitef(num)) *MSVCRT__errno() = MSVCRT_EDOM;
else if (!num) *MSVCRT__errno() = MSVCRT_ERANGE;
return logbf(num);
}
......@@ -789,6 +790,7 @@ __int64 CDECL _abs64( __int64 n )
double CDECL MSVCRT__logb(double num)
{
if (!isfinite(num)) *MSVCRT__errno() = MSVCRT_EDOM;
else if (!num) *MSVCRT__errno() = MSVCRT_ERANGE;
return logb(num);
}
......
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