summaryrefslogtreecommitdiff
path: root/sbin/ifconfig/sff.c
diff options
context:
space:
mode:
authorStuart Henderson <sthen@cvs.openbsd.org>2019-04-10 14:15:44 +0000
committerStuart Henderson <sthen@cvs.openbsd.org>2019-04-10 14:15:44 +0000
commit51e4de3477e93cfdc30a4feaec76173de3a329b8 (patch)
tree0ee9c6fda1e56f8b1e7b68bde465fb965679abcb /sbin/ifconfig/sff.c
parent8c796a28e21fc66fb8fdb9999ae07c07a5650e55 (diff)
use correct printf format for current dBm values
problem spotted by Hrvoje, thank you! ok deraadt
Diffstat (limited to 'sbin/ifconfig/sff.c')
-rw-r--r--sbin/ifconfig/sff.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sbin/ifconfig/sff.c b/sbin/ifconfig/sff.c
index 6a10cc9f417..0738bee914e 100644
--- a/sbin/ifconfig/sff.c
+++ b/sbin/ifconfig/sff.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sff.c,v 1.2 2019/04/10 10:45:50 sthen Exp $ */
+/* $OpenBSD: sff.c,v 1.3 2019/04/10 14:15:43 sthen Exp $ */
/*
* Copyright (c) 2019 David Gwynne <dlg@openbsd.org>
@@ -398,7 +398,7 @@ static void
if_sff_printalarm(const char *unit, int range, float actual,
float alrm_high, float alrm_low, float warn_high, float warn_log)
{
- printf("%.0f%s", actual, unit);
+ printf("%.02f%s", actual, unit);
if (range == 1)
printf(" (low %.02f%s high %.02f%s)", alrm_low,
unit, alrm_high, unit);