summaryrefslogtreecommitdiff
path: root/src/test
diff options
context:
space:
mode:
authorYu Watanabe <watanabe.yu+github@gmail.com>2018-10-13 23:59:16 +0900
committerYu Watanabe <watanabe.yu+github@gmail.com>2018-10-14 03:29:43 +0900
commit40990eac272b007c581932cfdd9bb43b7805a686 (patch)
tree116a481c0d060107e9063241e2eb6d2a297346ef /src/test
parent172e4806dd55e00e3713779846d58761dc50a733 (diff)
downloadsystemd-40990eac272b007c581932cfdd9bb43b7805a686.tar.gz
systemd-40990eac272b007c581932cfdd9bb43b7805a686.tar.bz2
systemd-40990eac272b007c581932cfdd9bb43b7805a686.zip
test: use fabsl instead of fabs as json_variant_real() returns 'long double'
Diffstat (limited to 'src/test')
-rw-r--r--src/test/test-json.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/test/test-json.c b/src/test/test-json.c
index c1c2105913..e145559ae9 100644
--- a/src/test/test-json.c
+++ b/src/test/test-json.c
@@ -208,7 +208,7 @@ static void test_2(JsonVariant *v) {
/* has thisisaverylongproperty */
p = json_variant_by_key(v, "thisisaverylongproperty");
- assert_se(p && json_variant_type(p) == JSON_VARIANT_REAL && fabs(json_variant_real(p) - 1.27) < 0.001);
+ assert_se(p && json_variant_type(p) == JSON_VARIANT_REAL && fabsl(json_variant_real(p) - 1.27) < 0.001);
}