mirror of
https://github.com/Llewellynvdm/conky.git
synced 2024-09-29 21:49:07 +00:00
Merge pull request #219 from mxmlnkn/doubletotaltraffic
solve double counting at start issue
This commit is contained in:
commit
448d13ff4d
@ -470,10 +470,12 @@ int update_net_stats(void)
|
|||||||
if (ns->last_read_recv == -1) {
|
if (ns->last_read_recv == -1) {
|
||||||
ns->recv = r;
|
ns->recv = r;
|
||||||
first = 1;
|
first = 1;
|
||||||
|
ns->last_read_recv = r;
|
||||||
}
|
}
|
||||||
if (ns->last_read_trans == -1) {
|
if (ns->last_read_trans == -1) {
|
||||||
ns->trans = t;
|
ns->trans = t;
|
||||||
first = 1;
|
first = 1;
|
||||||
|
ns->last_read_trans = t;
|
||||||
}
|
}
|
||||||
/* move current traffic statistic to last thereby obsoleting the
|
/* move current traffic statistic to last thereby obsoleting the
|
||||||
* current statistic */
|
* current statistic */
|
||||||
|
Loading…
Reference in New Issue
Block a user