OSSP CVS Repository

ossp - Difference in ossp-pkg/pth/pth_string.c versions 1.11 and 1.12
Not logged in
[Honeypot]  [Browse]  [Home]  [Login]  [Reports
[Search]  [Ticket]  [Timeline
  [History

ossp-pkg/pth/pth_string.c 1.11 -> 1.12

--- pth_string.c 2004/07/13 10:50:49     1.11
+++ pth_string.c 2004/07/13 10:53:53     1.12
@@ -476,7 +476,7 @@
 }
 
 static LDOUBLE
-abs_val(LDOUBLE value)
+math_abs(LDOUBLE value)
 {
     LDOUBLE result = value;
     if (value < 0)
@@ -485,7 +485,7 @@
 }
 
 static LDOUBLE
-pow10(int exponent)
+math_pow10(int exponent)
 {
     LDOUBLE result = 1;
     while (exponent > 0) {
@@ -496,7 +496,7 @@
 }
 
 static long
-round(LDOUBLE value)
+math_round(LDOUBLE value)
 {
     long intpart;
     intpart = (long) value;
@@ -530,7 +530,7 @@
 
     if (max < 0)
         max = 6;
-    ufvalue = abs_val(fvalue);
+    ufvalue = math_abs(fvalue);
     if (fvalue < 0)
         signvalue = '-';
     else if (flags & DP_F_PLUS)
@@ -547,11 +547,11 @@
 
     /* we "cheat" by converting the fractional part to integer by
        multiplying by a factor of 10 */
-    fracpart = round((pow10(max)) * (ufvalue - intpart));
+    fracpart = math_round((math_pow10(max)) * (ufvalue - intpart));
 
-    if (fracpart >= pow10(max)) {
+    if (fracpart >= math_pow10(max)) {
         intpart++;
-        fracpart -= pow10(max);
+        fracpart -= math_pow10(max);
     }
 
     /* convert integer part */

CVSTrac 2.0.1