test-alloc-util: assert on the return value to appease coverity

Coverity is right that we should check the return value…
CID#1403006.
This commit is contained in:
Zbigniew Jędrzejewski-Szmek
2019-07-11 11:19:19 +02:00
parent 0121d1f28d
commit 67da2cc883
+1 -1
View File
@@ -139,7 +139,7 @@ static void test_auto_erase_memory(void) {
assert_se(p1 = new(uint8_t, 1024));
assert_se(p2 = new(uint8_t, 1024));
genuine_random_bytes(p1, 1024, RANDOM_BLOCK);
assert_se(genuine_random_bytes(p1, 1024, RANDOM_BLOCK) == 0);
/* before we exit the scope, do something with this data, so that the compiler won't optimize this away */
memcpy(p2, p1, 1024);