From 75fb5b3e02f0e53ea469f6f83b311e7fedd80cd3 Mon Sep 17 00:00:00 2001 From: Enrico Joerns Date: Fri, 30 Aug 2024 11:31:23 +0200 Subject: [PATCH] fixup! test/hash_index: add test for invalid size for testing error handling --- test/hash_index.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/test/hash_index.c b/test/hash_index.c index 22eaa4e26..6e99724bd 100644 --- a/test/hash_index.c +++ b/test/hash_index.c @@ -298,9 +298,7 @@ static void test_invalid_size(Fixture *fixture, gconstpointer user_data) // open and calculate hash index index = r_hash_index_open("test", datafd, NULL, &error); g_assert_error(error, R_HASH_INDEX_ERROR, R_HASH_INDEX_ERROR_SIZE); - g_assert_nonnull(index); - datafd = -1; /* belongs to index now */ - (void)datafd; /* ignore dead store */ + g_assert_null(index); } int main(int argc, char *argv[])