From bf27121b5d01939c819ac8b5b96101a16175c4de Mon Sep 17 00:00:00 2001 From: "H. Joe Lee" Date: Fri, 7 Jan 2022 16:30:18 -0600 Subject: OESS-168: Remove clang warnings. (#1308) --- src/H5FDdirect.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/H5FDdirect.c b/src/H5FDdirect.c index d07d909..7a43117 100644 --- a/src/H5FDdirect.c +++ b/src/H5FDdirect.c @@ -213,8 +213,11 @@ H5FD_direct_init(void) else ignore_disabled_file_locks_s = FAIL; /* Environment variable not set, or not set correctly */ - if (H5I_VFL != H5I_get_type(H5FD_DIRECT_g)) + if (H5I_VFL != H5I_get_type(H5FD_DIRECT_g)) { H5FD_DIRECT_g = H5FD_register(&H5FD_direct_g, sizeof(H5FD_class_t), FALSE); + if (H5I_INVALID_HID == H5FD_DIRECT_g) + HGOTO_ERROR(H5E_ID, H5E_CANTREGISTER, H5I_INVALID_HID, "unable to register direct"); + } /* Set return value */ ret_value = H5FD_DIRECT_g; -- cgit v0.12