Spinner: use fabs for floating point absolute value. 55/46955/3
authorTom Hacohen <tom@stosb.com>
Wed, 22 Apr 2015 12:31:10 +0000 (13:31 +0100)
committerJaeun Choi <jaeun12.choi@samsung.com>
Thu, 27 Aug 2015 11:05:50 +0000 (04:05 -0700)
Change-Id: I2af89327e737a9a14f50ebe7150eacbefedc81f7
Origin: upstream

src/lib/elm_spinner.c

index 281cec4..413a092 100644 (file)
@@ -377,7 +377,7 @@ _spin_value(void *data)
    double real_speed = sd->spin_speed;
 
    /* Sanity check: our step size should be at least as large as our rounding value */
-   if ((sd->spin_speed != 0.0) && (abs(sd->spin_speed) < sd->round))
+   if ((sd->spin_speed != 0.0) && (fabs(sd->spin_speed) < sd->round))
      {
         WRN("The spinning step is smaller than the rounding value, please check your code");
         real_speed = sd->spin_speed > 0 ? sd->round : -sd->round;