Imported Upstream version 3.5.1
[platform/upstream/ccache.git] / src / stats.c
index ef6a291..51265aa 100644 (file)
@@ -51,7 +51,7 @@ static format_fn format_timestamp;
 // Statistics fields in display order.
 static struct {
        enum stats stat;
-       char *message;
+       const char *message;
        format_fn *format_fn; // NULL -> use plain integer format
        unsigned flags;
 } stats_info[] = {
@@ -515,7 +515,7 @@ stats_summary(void)
                        unsigned hit = direct + preprocessed;
                        unsigned miss = counters->data[STATS_TOCACHE];
                        unsigned total = hit + miss;
-                       double percent = total > 0 ? (100.0f * hit) / total : 0.0f;
+                       double percent = total > 0 ? (100.0 * hit) / total : 0.0;
                        printf("cache hit rate                    %6.2f %%\n", percent);
                }
        }