From fec51a2362eb35edd596ae6b6117c668b6e8a539 Mon Sep 17 00:00:00 2001 From: Alexey Kardashevskiy Date: Wed, 2 Sep 2020 18:16:10 +1000 Subject: executor: compile fix MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This fixes an error in printf() format for __u64: gcc -o ./bin/linux_ppc64le/syz-executor executor/executor.cc \ -D__powerpc64__ -O2 -pthread -Wall -Werror -Wparentheses \ -Wunused-const-variable -Wframe-larger-than=16384 -static -DGOOS_linux=1 -DGOARCH_ppc64le=1 \ -DHOSTGOOS_linux=1 \ -DGIT_REVISION=\"82d2e60626ef1f43e557ca2933aee53bd5265eaf+\" In file included from executor/test.h:5:0, from executor/executor.cc:343: executor/test_linux.h: In function ‘int test_one(int, const char*, int, \ int, unsigned int, bool)’: executor/test_linux.h:74:60: error: format ‘%llx’ expects argument of type \ ‘long long unsigned int’, but argument 2 has type ‘__u64 {aka long unsigned int}’ [-Werror=format=] cpu_mem->fail_entry.hardware_entry_failure_reason); ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^ Signed-off-by: Alexey Kardashevskiy --- executor/test_linux.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'executor') diff --git a/executor/test_linux.h b/executor/test_linux.h index 96e185175..fcd8d855e 100644 --- a/executor/test_linux.h +++ b/executor/test_linux.h @@ -71,7 +71,7 @@ static int test_one(int text_type, const char* text, int text_size, int flags, u printf("KVM_RUN exit reason %d, expect %d\n", cpu_mem->exit_reason, reason); if (cpu_mem->exit_reason == KVM_EXIT_FAIL_ENTRY) printf("hardware exit reason 0x%llx\n", - cpu_mem->fail_entry.hardware_entry_failure_reason); + (unsigned long long)cpu_mem->fail_entry.hardware_entry_failure_reason); dump_cpu_state(cpufd, (char*)vm_mem); return 1; } -- cgit mrf-deployment