summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2019-07-11 07:45:13 +0200
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2019-07-11 11:19:19 +0200
commit67da2cc883fb261d2f9e5819df5646b2165196a8 (patch)
tree92fc2654b16acd354383676c1ecfde9a4fe39bc6 /src
parentpid1: shorten dump output a bit by not repeating unit id twice (diff)
downloadsystemd-67da2cc883fb261d2f9e5819df5646b2165196a8.tar.xz
systemd-67da2cc883fb261d2f9e5819df5646b2165196a8.zip
test-alloc-util: assert on the return value to appease coverity
Coverity is right that we should check the return value… CID#1403006.
Diffstat (limited to 'src')
-rw-r--r--src/test/test-alloc-util.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/test/test-alloc-util.c b/src/test/test-alloc-util.c
index cf69436d26..71ecda0b99 100644
--- a/src/test/test-alloc-util.c
+++ b/src/test/test-alloc-util.c
@@ -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);