diff options
author | Ryo Nakamura <upa@haeena.net> | 2022-10-23 16:10:07 +0900 |
---|---|---|
committer | Ryo Nakamura <upa@haeena.net> | 2022-10-23 16:10:07 +0900 |
commit | 7c18d42004c346a3f9fbded602f39d757dc4926d (patch) | |
tree | a76024fed5e1bfe375cdc1c604e635ef148a52f4 | |
parent | 03a20c77d8abf86616cef9e7671b80cfcce42a2f (diff) |
bps to byte/s
-rw-r--r-- | src/main.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -395,7 +395,7 @@ static double calculate_bps(size_t diff, struct timeval *b, struct timeval *a) usec = a->tv_usec - b->tv_usec; sec += usec / 1000000; - return (double)diff / sec * 8; + return (double)diff / sec; } static void print_progress(double percent, char *suffix) @@ -451,7 +451,7 @@ void *sscp_monitor_thread(void *arg) size_t total, total_round, done, last; int percent; double bps; - char *bps_units[] = { "bps", "Kbps", "Mbps", "Gbps" }; + char *bps_units[] = { "B/s", "KB/s", "MB/s", "GB/s" }; char *byte_units[] = { "B", "KB", "MB", "GB", "TB", "PB" }; int n, bps_u, byte_tu, byte_du; |