From 9cd9153a4d4cf78011d2a8f8c7a69aa8f3eda9f3 Mon Sep 17 00:00:00 2001 From: Stef Walter Date: Fri, 8 Aug 2014 17:18:10 +0200 Subject: Fix mostly erroneous scanner warnings in tests --- common/tests/test-dict.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'common/tests/test-dict.c') diff --git a/common/tests/test-dict.c b/common/tests/test-dict.c index 7c6f851..f12a34e 100644 --- a/common/tests/test-dict.c +++ b/common/tests/test-dict.c @@ -426,6 +426,7 @@ test_hash_add_check_lots_and_collisions (void) for (i = 0; i < 20000; ++i) { value = malloc (sizeof (int)); + assert (value != NULL); *value = i; if (!p11_dict_set (map, value, value)) assert_not_reached (); @@ -454,6 +455,7 @@ test_hash_count (void) for (i = 0; i < 20000; ++i) { value = malloc (sizeof (int)); + assert (value != NULL); *value = i; if (!p11_dict_set (map, value, value)) assert_not_reached (); @@ -483,6 +485,7 @@ test_hash_ulongptr (void) for (i = 0; i < 20000; ++i) { value = malloc (sizeof (unsigned long)); + assert (value != NULL); *value = i; if (!p11_dict_set (map, value, value)) assert_not_reached (); -- cgit v1.1