From 9b6d1bf324fd6725f45de3518fa2b4c55de80a49 Mon Sep 17 00:00:00 2001 From: Nguyen Anh Quynh Date: Fri, 5 Feb 2016 08:54:52 +0800 Subject: [PATCH] regress: fix compilation warning for mem_fuzz.c --- .gitignore | 1 + tests/regress/mem_fuzz.c | 8 ++++---- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/.gitignore b/.gitignore index d3ddf440..8d291285 100644 --- a/.gitignore +++ b/.gitignore @@ -137,6 +137,7 @@ sysenter_hook_x86 test_tb_x86 test_multihook test_pc_change +mem_fuzz ################# diff --git a/tests/regress/mem_fuzz.c b/tests/regress/mem_fuzz.c index a1e080cf..aee3cdb0 100644 --- a/tests/regress/mem_fuzz.c +++ b/tests/regress/mem_fuzz.c @@ -44,14 +44,14 @@ uint64_t get_aligned_len(){ void perform_map_step(uc_engine *uc){ uint64_t addr = get_aligned_addr(); uint64_t len = get_aligned_len(); - printf("map(0x%lx,0x%lx); //%d\n", addr, len, step); + printf("map(0x%"PRIx64",0x%"PRIx64"); //%d\n", addr, len, step); uc_mem_map(uc, addr, len, UC_PROT_READ | UC_PROT_WRITE); } void perform_unmap_step(uc_engine *uc){ uint64_t addr = get_aligned_addr(); uint64_t len = get_aligned_len(); - printf("unmap(0x%lx,0x%lx); //%d\n", addr, len, step); + printf("unmap(0x%"PRIx64",0x%"PRIx64"); //%d\n", addr, len, step); uc_mem_unmap(uc, addr, len); } @@ -60,7 +60,7 @@ void perform_write_step(uc_engine *uc){ memset(buff, 0, 4096*4); uint64_t addr = get_addr(); uint64_t len = get_len()%(4096*3); - printf("write(0x%lx,0x%lx); //%d\n", addr, len, step); + printf("write(0x%"PRIx64",0x%"PRIx64"); //%d\n", addr, len, step); uc_mem_write(uc, addr, buff, len); } @@ -68,7 +68,7 @@ void perform_read_step(uc_engine *uc){ char* buff[4096*4]; uint64_t addr = get_addr(); uint64_t len = get_len()%(4096*3); - printf("read(0x%lx,0x%lx); //%d\n", addr, len, step); + printf("read(0x%"PRIx64",0x%"PRIx64"); //%d\n", addr, len, step); uc_mem_read(uc, addr, buff, len); }