diff options
author | Øyvind Kolås <pippin@gimp.org> | 2022-01-26 15:07:56 +0100 |
---|---|---|
committer | Øyvind Kolås <pippin@gimp.org> | 2022-01-26 15:09:10 +0100 |
commit | f2c4b35fae150b3b1190009dfa26741103ab8e46 (patch) | |
tree | 10a2ccc775264402e4bb7e0be830caf67a654c5a /tools | |
parent | 2f40f47b9e33fc4858d005827ff1c19554d762b1 (diff) |
babl: clean up compiler warnings
Diffstat (limited to 'tools')
-rw-r--r-- | tools/babl-benchmark.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/tools/babl-benchmark.c b/tools/babl-benchmark.c index ee1df45..0ead0cb 100644 --- a/tools/babl-benchmark.c +++ b/tools/babl-benchmark.c @@ -203,10 +203,10 @@ test (int set_no) int set_iter = 0; int first_run = 1; float max_throughput = 0; + double max = 0.0; if (set_no > n_sets-1) set_no = n_sets-1; - double max = 0.0; while (set_iter < n_sets) { double sum = 0; @@ -271,12 +271,15 @@ test (int set_no) fprintf (stdout, " \r"); + { float throughput = sum / n; - if (throughput > max_throughput) max_throughput = throughput; + if (throughput > max_throughput) + max_throughput = throughput; fprintf (stdout, "%s %03.3f mp/s\tWorkflow: %s to %s\n\n", unicode_hbar(BAR_WIDTH, throughput / max_throughput), throughput, babl_get_name (formats[0]), babl_get_name (formats[n_formats-1])); + } if (mbps[n] > max && first_run) max = mbps[n]; |