From 309dca417cf4784c6453602aadd61bd9dd084878 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ond=C5=99ej=20Sur=C3=BD?= Date: Sun, 13 Oct 2019 07:02:34 +0200 Subject: [PATCH] tests: Resolve scan-build false positive by adding extra assertion --- bin/tests/system/dlzexternal/driver.c | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/tests/system/dlzexternal/driver.c b/bin/tests/system/dlzexternal/driver.c index 310220b1b7..b969b9e053 100644 --- a/bin/tests/system/dlzexternal/driver.c +++ b/bin/tests/system/dlzexternal/driver.c @@ -99,6 +99,7 @@ add_name(struct dlz_example_data *state, struct record *list, int first_empty = -1; for (i = 0; i < MAX_RECORDS; i++) { + INSIST(list[i].name != NULL); if (first_empty == -1 && strlen(list[i].name) == 0U) { first_empty = i; }