summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHenning Brauer <henning@cvs.openbsd.org>2002-12-17 00:00:09 +0000
committerHenning Brauer <henning@cvs.openbsd.org>2002-12-17 00:00:09 +0000
commitc6213166e465859549c890bfa67c6bb800040931 (patch)
tree16cf13778068b4554cd6d11bff4ece0c47e2d2f2
parent31e05b52fc27c9fc038e3facee17f9149bc96be7 (diff)
duh. two checks in rate2str which decide wether to print Mb or Kb had 1024
instead of 1000 in. cosmetic changes if at all.
-rw-r--r--sbin/pfctl/pfctl_altq.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sbin/pfctl/pfctl_altq.c b/sbin/pfctl/pfctl_altq.c
index 95c207eda41..96f6a52ca14 100644
--- a/sbin/pfctl/pfctl_altq.c
+++ b/sbin/pfctl/pfctl_altq.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pfctl_altq.c,v 1.21 2002/12/16 23:06:28 henning Exp $ */
+/* $OpenBSD: pfctl_altq.c,v 1.22 2002/12/17 00:00:08 henning Exp $ */
/*
* Copyright (C) 2002
@@ -605,9 +605,9 @@ rate2str(double rate)
else if (rate >= 1000 * 1000 * 1000)
snprintf(buf, RATESTR_MAX, "%.2fGb",
rate / (1000.0 * 1000.0 * 1000.0));
- else if (rate >= 1024 * 1024)
+ else if (rate >= 1000 * 1000)
snprintf(buf, RATESTR_MAX, "%.2fMb", rate / (1000.0 * 1000.0));
- else if (rate >= 1024)
+ else if (rate >= 1000)
snprintf(buf, RATESTR_MAX, "%.2fKb", rate / 1000.0);
else
snprintf(buf, RATESTR_MAX, "%db", (int)rate);