Suppress compiler warnings "warning: format '%ld' expects argument of type 'long int', but argument 4 has type 'uint64_t' [-Wformat=]" and similar ones generated on 32-bit architectures as a result of commit 3fedbee9bfbb ("vmware_guestdump: new input format"). Signed-off-by: Kazuhito Hagio <k-hagio-ab@xxxxxxx> --- I missed those, I think we should fix before the release. vmware_guestdump.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/vmware_guestdump.c b/vmware_guestdump.c index d3fac5944026..62da0a77a227 100644 --- a/vmware_guestdump.c +++ b/vmware_guestdump.c @@ -292,9 +292,9 @@ int vmware_guestdump_memory_dump(FILE *ofp) { fprintf(ofp, "vmware_guestdump:\n"); - fprintf(ofp, " Header: version=%d num_vcpus=%ld\n", - GUESTDUMP_VERSION, vmss.num_vcpus); - fprintf(ofp, "Total memory: %ld\n", vmss.memsize); + fprintf(ofp, " Header: version=%d num_vcpus=%llu\n", + GUESTDUMP_VERSION, (ulonglong)vmss.num_vcpus); + fprintf(ofp, "Total memory: %llu\n", (ulonglong)vmss.memsize); if (vmss.regionscount > 1) { uint64_t holes_sum = 0; @@ -303,11 +303,11 @@ vmware_guestdump_memory_dump(FILE *ofp) fprintf(ofp, "Memory regions[%d]:\n", vmss.regionscount); fprintf(ofp, " [0x%016x-", 0); for (i = 0; i < vmss.regionscount - 1; i++) { - fprintf(ofp, "0x%016lx]\n", (uint64_t)vmss.regions[i].startpagenum << VMW_PAGE_SHIFT); - fprintf(ofp, " [0x%016lx-", (uint64_t)vmss.regions[i].startppn << VMW_PAGE_SHIFT); + fprintf(ofp, "0x%016llx]\n", (ulonglong)vmss.regions[i].startpagenum << VMW_PAGE_SHIFT); + fprintf(ofp, " [0x%016llx-", (ulonglong)vmss.regions[i].startppn << VMW_PAGE_SHIFT); holes_sum += vmss.regions[i].startppn - vmss.regions[i].startpagenum; } - fprintf(ofp, "0x%016lx]\n", vmss.memsize + (holes_sum << VMW_PAGE_SHIFT)); + fprintf(ofp, "0x%016llx]\n", (ulonglong)vmss.memsize + (holes_sum << VMW_PAGE_SHIFT)); } return TRUE; -- Crash-utility mailing list Crash-utility@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/crash-utility