diff options
author | van Hauser <vh@thc.org> | 2020-08-12 14:29:34 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-08-12 14:29:34 +0200 |
commit | 8044ae28be2dd109ac16719ce2e304074fa74efd (patch) | |
tree | dedf9bafaf8d176bc07912a2f512187af9048f36 /test/unittests/unit_list.c | |
parent | 986af28df27016813abdfdde8bdedda1f571703c (diff) | |
parent | b38837f4ff8f2e52597b7908b9226500e5c61933 (diff) | |
download | afl++-8044ae28be2dd109ac16719ce2e304074fa74efd.tar.gz |
Merge pull request #496 from AFLplusplus/dev
push to stable
Diffstat (limited to 'test/unittests/unit_list.c')
-rw-r--r-- | test/unittests/unit_list.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/test/unittests/unit_list.c b/test/unittests/unit_list.c index 4c2063b6..43665f1a 100644 --- a/test/unittests/unit_list.c +++ b/test/unittests/unit_list.c @@ -27,23 +27,26 @@ extern void mock_assert(const int result, const char* const expression, (compile with `--wrap=exit`) */ extern void exit(int status); extern void __real_exit(int status); -void __wrap_exit(int status); +//void __wrap_exit(int status); void __wrap_exit(int status) { + (void)status; assert(0); } /* ignore all printfs */ #undef printf extern int printf(const char *format, ...); -extern int __real_printf(const char *format, ...); +//extern int __real_printf(const char *format, ...); int __wrap_printf(const char *format, ...); int __wrap_printf(const char *format, ...) { + (void)format; return 1; } static list_t testlist = {.element_prealloc_count = 0}; static void test_contains(void **state) { + (void)state; u32 one = 1; u32 two = 2; @@ -56,6 +59,7 @@ static void test_contains(void **state) { } static void test_foreach(void **state) { + (void)state; u32 one = 1; u32 two = 2; @@ -75,6 +79,7 @@ static void test_foreach(void **state) { } static void test_long_list(void **state) { + (void)state; u32 result1 = 0; u32 result2 = 0; @@ -118,6 +123,8 @@ static void test_long_list(void **state) { } int main(int argc, char **argv) { + (void)argc; + (void)argv; const struct CMUnitTest tests[] = { cmocka_unit_test(test_contains), |