Browse Source

* don't "round" 0.0 when converting to a string (mantis #12202)

git-svn-id: trunk@11823 -
Jonas Maebe 17 years ago
parent
commit
b2531e9883
1 changed files with 2 additions and 1 deletions
  1. 2 1
      rtl/inc/real2str.inc

+ 2 - 1
rtl/inc/real2str.inc

@@ -367,7 +367,8 @@ begin
           for fracCount := 1 to currPrec do
           for fracCount := 1 to currPrec do
             factor := factor * 10.0;
             factor := factor * 10.0;
           corrval := corrval / factor;
           corrval := corrval / factor;
-          d:=d+roundCorr;
+          if (d<>0.0) then
+            d:=d+roundCorr;
           if d >= corrVal then
           if d >= corrVal then
             d := d + corrVal;
             d := d + corrVal;
           if int(d) = 1 then
           if int(d) = 1 then