commit 2717fca0bd9353a2534728448fa04ed0d0a376ac
parent ab9b0adb937fc9fb83782a8e812239cc5f67b5b8
Author: Christian Grothoff <christian@grothoff.org>
Date: Thu, 10 Apr 2025 18:56:33 +0200
-fix pedantic compiler warning
Diffstat:
2 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/src/exchange/Makefile.am b/src/exchange/Makefile.am
@@ -113,6 +113,7 @@ taler_exchange_sanctionscheck_LDADD = \
-lgnunetjson \
-ljansson \
-lgnunetutil \
+ -lm \
$(XLIB)
taler_exchange_transfer_SOURCES = \
diff --git a/src/exchange/taler-exchange-sanctionscheck.c b/src/exchange/taler-exchange-sanctionscheck.c
@@ -27,7 +27,7 @@
#include "taler_exchangedb_plugin.h"
#include "taler_json_lib.h"
#include "taler_kyclogic_lib.h"
-
+#include <math.h>
/**
* Account we are currently checking.
@@ -150,9 +150,12 @@ shutdown_task (void *cls)
static uint64_t
double_to_billion (double d)
{
+ double r;
+
GNUNET_break (d >= 0);
GNUNET_break (d <= 1.0);
- return (uint64_t) round (d * 1000000000);
+ r = round (d * 1000000000);
+ return (uint64_t) r;
}