From 8ccadeb7bb622d56fe79e1ef26eb1c83b0737909 Mon Sep 17 00:00:00 2001 From: mxmlnkn Date: Sun, 21 Feb 2016 10:34:46 +0100 Subject: [PATCH] solve double counting at start issue --- src/linux.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/linux.cc b/src/linux.cc index 62d95b55..ddc9bd24 100644 --- a/src/linux.cc +++ b/src/linux.cc @@ -470,10 +470,12 @@ int update_net_stats(void) if (ns->last_read_recv == -1) { ns->recv = r; first = 1; + ns->last_read_recv = r; } if (ns->last_read_trans == -1) { ns->trans = t; first = 1; + ns->last_read_trans = t; } /* move current traffic statistic to last thereby obsoleting the * current statistic */