aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordemon <demon@FreeBSD.org>2005-05-17 14:31:26 +0800
committerdemon <demon@FreeBSD.org>2005-05-17 14:31:26 +0800
commit7c113fb34287319b6a2ed83664c1138a30d82978 (patch)
treefb69f810702777d87fcc2aa5dd8f4c7d5bc849cd
parentf0cb1d4c229e32686940a4c0fec85b30acc5b48f (diff)
downloadfreebsd-ports-gnome-7c113fb34287319b6a2ed83664c1138a30d82978.tar.gz
freebsd-ports-gnome-7c113fb34287319b6a2ed83664c1138a30d82978.tar.zst
freebsd-ports-gnome-7c113fb34287319b6a2ed83664c1138a30d82978.zip
Fix a problem when all graphs are being drawn as if "Unscaled" was set.
Submitted by: Jeremy Chadwick <freebsd@jdc.parodius.com> PR: 81117
-rw-r--r--net-mgmt/mrtg/files/patch-src-rateup.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/net-mgmt/mrtg/files/patch-src-rateup.c b/net-mgmt/mrtg/files/patch-src-rateup.c
new file mode 100644
index 000000000000..285b56715aab
--- /dev/null
+++ b/net-mgmt/mrtg/files/patch-src-rateup.c
@@ -0,0 +1,18 @@
+--- src/rateup.c~ 2005-05-16 19:15:06.468444000 +0200
++++ src/rateup.c 2005-05-16 19:15:09.138421000 +0200
+@@ -318,6 +318,7 @@
+ }
+
+ /* multiplicator for bits/bytes */
++ maxv = (long long) max (maxvi, maxvo);
+ maxvi = maxvi < (long long) 0 ? -maxvi : maxvi;
+ maxvo = maxvo < (long long) 0 ? -maxvo : maxvo;
+ origmaxvi = maxvi;
+@@ -328,7 +329,6 @@
+ maxvi *= muli;
+ maxvo *= muli;
+ }
+- maxv = (long long) max (maxvi, maxvo);
+ if (step > MONTH_SAMPLE)
+ {
+ type = 4;