android: fix compile by not defining FIO_NO_HAVE_SHM_H twice
[fio.git] / stat.c
diff --git a/stat.c b/stat.c
index 28acc233870fea2fa9e29abd8d5664b2101e7b89..fe09a2968e6b4cfea853ef526640fd46eee58faa 100644 (file)
--- a/stat.c
+++ b/stat.c
@@ -182,7 +182,7 @@ static unsigned int calc_clat_percentiles(unsigned int *io_u_plat,
  * Find and display the p-th percentile of clat
  */
 static void show_clat_percentiles(unsigned int *io_u_plat, unsigned long nr,
-                                 fio_fp64_t *plist, uint64_t precision)
+                                 fio_fp64_t *plist, unsigned int precision)
 {
        unsigned int len, j = 0, minv, maxv;
        unsigned int *ovals;
@@ -205,7 +205,7 @@ static void show_clat_percentiles(unsigned int *io_u_plat, unsigned long nr,
                log_info("    clat percentiles (usec):\n     |");
        }
 
-       snprintf(fmt, sizeof(fmt), "%%1.%luf", precision);
+       snprintf(fmt, sizeof(fmt), "%%1.%uf", precision);
        per_line = (80 - 7) / (precision + 14);
 
        for (j = 0; j < len; j++) {
@@ -1358,10 +1358,10 @@ void show_run_stats(void)
 
        if (is_backend)
                fio_server_send_du();
-       else if (output_format == FIO_OUTPUT_NORMAL)
+       else if (output_format == FIO_OUTPUT_NORMAL) {
                show_disk_util(0, NULL);
-
-       show_idle_prof_stats(FIO_OUTPUT_NORMAL, NULL);
+               show_idle_prof_stats(FIO_OUTPUT_NORMAL, NULL);
+       }
 
        free(runstats);
        free(threadstats);