diff options
Diffstat (limited to 'fsbm.c')
-rw-r--r-- | fsbm.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -98,7 +98,7 @@ void print_stats() { len = name - buf; // Parse the statistics, alls well, then get this shit going, otherwise f it. - if (sscanf(stats, "%Lu %*Lu %*Lu %*Lu %*Lu %*Lu %*Lu %*Lu %Lu", + if(sscanf(stats, "%Lu %*Lu %*Lu %*Lu %*Lu %*Lu %*Lu %*Lu %Lu", &rx_bytes, &tx_bytes) == 2) { size_t i = 0; @@ -119,7 +119,7 @@ void print_stats() { // print our new speeds timeDelta = (timestamp.tv_sec - interfaces[i].timestamp.tv_sec) * 1.0 + - (timestamp.tv_usec - interfaces[i].timestamp.tv_usec) * .000001; + (timestamp.tv_usec - interfaces[i].timestamp.tv_usec) * .000001; rx_speed = (rx_bytes - interfaces[i].rx_bytes) / timeDelta; tx_speed = (tx_bytes - interfaces[i].tx_bytes) / timeDelta; |