From d09525718b88039b4c6a6af3e5825cb8c2ee3914 Mon Sep 17 00:00:00 2001
From: Jes Sorensen <Jes.Sorensen@redhat.com>
Date: Mon, 31 Jan 2011 12:23:28 -0200
Subject: [PATCH 34/37] strtosz(): Fix name confusion in use of modf()

RH-Author: Jes Sorensen <Jes.Sorensen@redhat.com>
Message-id: <1296476610-28514-25-git-send-email-Jes.Sorensen@redhat.com>
Patchwork-id: 17320
O-Subject: [PATCH 24/26] strtosz(): Fix name confusion in use of modf()
Bugzilla: 637701
RH-Acked-by: Alex Williamson <alex.williamson@redhat.com>
RH-Acked-by: Marcelo Tosatti <mtosatti@redhat.com>
RH-Acked-by: Kevin Wolf <kwolf@redhat.com>

From: Jes Sorensen <Jes.Sorensen@redhat.com>

Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
(cherry picked from block branch)
---
 cutils.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
---
 cutils.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/cutils.c b/cutils.c
index edf8880..6b1b754 100644
--- a/cutils.c
+++ b/cutils.c
@@ -292,8 +292,8 @@ int64_t strtosz_suffix(const char *nptr, char **end, const char default_suffix)
     if (isnan(val) || endptr == nptr || errno != 0) {
         goto fail;
     }
-    integral = modf(val, &fraction);
-    if (integral != 0) {
+    fraction = modf(val, &integral);
+    if (fraction != 0) {
         mul_required = 1;
     }
     /*
-- 
1.7.4.rc1.16.gd2f15e

