]> git.ozlabs.org Git - ccan/blobdiff - ccan/tally/tally.c
tally: Fix a c++ warning
[ccan] / ccan / tally / tally.c
index d3d320eb1b0657d0e53bf2d042d49f913f207fdd..2af7353380f9af18221971aba90d1f7648ab8b2b 100644 (file)
@@ -450,7 +450,7 @@ char *tally_histogram(const struct tally *tally,
                        largest_bucket = tally->counts[i];
        }
 
                        largest_bucket = tally->counts[i];
        }
 
-       p = graph = malloc(height * (width + 1) + 1);
+       p = graph = (char *)malloc(height * (width + 1) + 1);
        if (!graph) {
                free(tmp);
                return NULL;
        if (!graph) {
                free(tmp);
                return NULL;