From f67c281f9841a5b1b18bc0f5aefa8701b318dd32 Mon Sep 17 00:00:00 2001 From: Arnaldo Carvalho de Melo Date: Tue, 2 Jul 2019 12:11:27 -0300 Subject: [PATCH] fprintf: Correct the type for the 'cacheline' variable, it should be uint32_t MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [ 22%] Building C object CMakeFiles/dwarves.dir/dwarves_fprintf.c.o /home/acme/git/pahole/dwarves_fprintf.c: In function ‘union__fprintf’: /home/acme/git/pahole/dwarves_fprintf.c:963:34: error: pointer targets in assignment from ‘int *’ to ‘uint32_t *’ {aka ‘unsigned int *’} differ in signedness [-Werror=pointer-sign] uconf.cachelinep = &cacheline; ^ cc1: all warnings being treated as errors Signed-off-by: Arnaldo Carvalho de Melo --- dwarves_fprintf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dwarves_fprintf.c b/dwarves_fprintf.c index 181bada..fdf74a6 100644 --- a/dwarves_fprintf.c +++ b/dwarves_fprintf.c @@ -930,7 +930,7 @@ static size_t union__fprintf(struct type *type, const struct cu *cu, int indent = conf->indent; struct conf_fprintf uconf; uint32_t initial_union_cacheline; - int cacheline = 0; /* This will only be used if this is the outermost union */ + uint32_t cacheline = 0; /* This will only be used if this is the outermost union */ if (indent >= (int)sizeof(tabs)) indent = sizeof(tabs) - 1;