From 935fbcdf5c9adee08f6fa50ba4a5ddbe7806f7f2 Mon Sep 17 00:00:00 2001 From: Tomasz Zawadzki Date: Fri, 6 Mar 2020 10:18:44 -0500 Subject: [PATCH] ut/blob: do not clear g_bs in helper functions Next patch in series adds setup/cleanup functions that use g_bs for its operation. Particular unit tests should not leave the g_bs unassigned, if cleanup is supposed to unload it. It applies to helper functions to reload/dirty_load. Signed-off-by: Tomasz Zawadzki Change-Id: I6e022b6c762981c2c70ebf31f4981a17f54f3591 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/1182 Tested-by: SPDK CI Jenkins Reviewed-by: Paul Luse Reviewed-by: Ben Walker Reviewed-by: Shuhei Matsumoto --- test/unit/lib/blob/blob.c/blob_ut.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/test/unit/lib/blob/blob.c/blob_ut.c b/test/unit/lib/blob/blob.c/blob_ut.c index ba89ed972..0ddd45968 100644 --- a/test/unit/lib/blob/blob.c/blob_ut.c +++ b/test/unit/lib/blob/blob.c/blob_ut.c @@ -182,7 +182,6 @@ ut_bs_reload(struct spdk_blob_store **bs, struct spdk_bs_opts *opts) SPDK_CU_ASSERT_FATAL(g_bs != NULL); *bs = g_bs; - g_bs = NULL; g_bserrno = -1; } @@ -202,7 +201,6 @@ ut_bs_dirty_load(struct spdk_blob_store **bs, struct spdk_bs_opts *opts) SPDK_CU_ASSERT_FATAL(g_bs != NULL); *bs = g_bs; - g_bs = NULL; g_bserrno = -1; }