From: Andreas Schneider Date: Mon, 5 Oct 2015 07:23:35 +0000 (+0200) Subject: src: Fix some compiler warnings X-Git-Tag: cmocka-1.1.1~33 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=1b595a80934fa95234fb290913cfe533f740d965;p=platform%2Fupstream%2Fcmocka.git src: Fix some compiler warnings BUG: https://open.cryptomilk.org/issues/43 --- diff --git a/src/cmocka.c b/src/cmocka.c index 1a41e52..a4dbae8 100644 --- a/src/cmocka.c +++ b/src/cmocka.c @@ -975,8 +975,8 @@ static int memory_equal_display_error(const char* const a, const char* const b, } } if (differences) { - cm_print_error("%d bytes of %p and %p differ\n", differences, - a, b); + cm_print_error("%d bytes of %p and %p differ\n", + differences, (void *)a, (void *)b); return 0; } return 1; @@ -1000,8 +1000,8 @@ static int memory_not_equal_display_error( } } if (same == size) { - cm_print_error("%"PRIdS "bytes of %p and %p the same\n", same, - a, b); + cm_print_error("%"PRIdS "bytes of %p and %p the same\n", + same, (void *)a, (void *)b); return 0; } return 1; @@ -1662,7 +1662,7 @@ void _test_free(void* const ptr, const char* file, const int line) { file, line, ptr, (unsigned long)block_info->size, block_info->location.file, block_info->location.line, - &guard[j]); + (void *)&guard[j]); _fail(file, line); } }