Explorar o código

* set result of exp() to 0 in case of underflow with masked exceptions
(mantis #21265)

git-svn-id: trunk@20368 -

Jonas Maebe %!s(int64=13) %!d(string=hai) anos
pai
achega
e8dae4f30a
Modificáronse 1 ficheiros con 2 adicións e 0 borrados
  1. 2 0
      rtl/inc/genmath.inc

+ 2 - 0
rtl/inc/genmath.inc

@@ -799,6 +799,7 @@ invalid:
             end;
             if d < u_threshold then begin
               float_raise(float_flag_underflow); { underflow }
+              result:=0; { Result if underflow masked }
               exit;
             end;
           end;
@@ -913,6 +914,7 @@ invalid:
       if( d < MINLOG ) then
       begin
         float_raise(float_flag_underflow);
+        result:=0; { Result if underflow masked }
       end
       else
       begin