summaryrefslogtreecommitdiffstats
path: root/src/H5FDlog.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/H5FDlog.c')
-rw-r--r--src/H5FDlog.c25
1 files changed, 12 insertions, 13 deletions
diff --git a/src/H5FDlog.c b/src/H5FDlog.c
index e8695c5..eb2c0e3 100644
--- a/src/H5FDlog.c
+++ b/src/H5FDlog.c
@@ -26,8 +26,7 @@
* With custom modifications...
*/
-/* Interface initialization */
-#define H5_INTERFACE_INIT_FUNC H5FD_log_init_interface
+#include "H5FDdrvr_module.h" /* This source code file is part of the H5FD driver module */
#include "H5private.h" /* Generic Functions */
@@ -221,7 +220,7 @@ H5FL_DEFINE_STATIC(H5FD_log_t);
/*-------------------------------------------------------------------------
- * Function: H5FD_log_init_interface
+ * Function: H5FD__init_package
*
* Purpose: Initializes any interface-specific data or routines.
*
@@ -230,18 +229,18 @@ H5FL_DEFINE_STATIC(H5FD_log_t);
*-------------------------------------------------------------------------
*/
static herr_t
-H5FD_log_init_interface(void)
+H5FD__init_package(void)
{
herr_t ret_value = SUCCEED;
- FUNC_ENTER_NOAPI_NOINIT
+ FUNC_ENTER_STATIC
if(H5FD_log_init() < 0)
HGOTO_ERROR(H5E_VFL, H5E_CANTINIT, FAIL, "unable to initialize log VFD")
done:
FUNC_LEAVE_NOAPI(ret_value)
-} /* H5FD_log_init_interface() */
+} /* H5FD__init_package() */
/*-------------------------------------------------------------------------
@@ -261,7 +260,7 @@ done:
hid_t
H5FD_log_init(void)
{
- hid_t ret_value; /* Return value */
+ hid_t ret_value = H5I_INVALID_HID; /* Return value */
FUNC_ENTER_NOAPI(FAIL)
@@ -361,7 +360,7 @@ static void *
H5FD_log_fapl_get(H5FD_t *_file)
{
H5FD_log_t *file = (H5FD_log_t *)_file;
- void *ret_value; /* Return value */
+ void *ret_value = NULL; /* Return value */
FUNC_ENTER_NOAPI_NOINIT_NOERR
@@ -390,7 +389,7 @@ H5FD_log_fapl_copy(const void *_old_fa)
{
const H5FD_log_fapl_t *old_fa = (const H5FD_log_fapl_t*)_old_fa;
H5FD_log_fapl_t *new_fa = NULL; /* New FAPL info */
- void *ret_value; /* Return value */
+ void *ret_value = NULL; /* Return value */
FUNC_ENTER_NOAPI_NOINIT
@@ -471,7 +470,7 @@ H5FD_log_open(const char *name, unsigned flags, hid_t fapl_id, haddr_t maxaddr)
{
H5FD_log_t *file = NULL;
H5P_genplist_t *plist; /* Property list */
- H5FD_log_fapl_t *fa; /* File access property list information */
+ const H5FD_log_fapl_t *fa; /* File access property list information */
int fd = -1; /* File descriptor */
int o_flags; /* Flags for open() call */
#ifdef H5_HAVE_WIN32_API
@@ -483,7 +482,7 @@ H5FD_log_open(const char *name, unsigned flags, hid_t fapl_id, haddr_t maxaddr)
struct timeval stat_timeval_diff;
#endif /* H5_HAVE_GETTIMEOFDAY */
h5_stat_t sb;
- H5FD_t *ret_value; /* Return value */
+ H5FD_t *ret_value = NULL; /* Return value */
FUNC_ENTER_NOAPI_NOINIT
@@ -510,7 +509,7 @@ H5FD_log_open(const char *name, unsigned flags, hid_t fapl_id, haddr_t maxaddr)
/* Get the driver specific information */
if(NULL == (plist = H5P_object_verify(fapl_id, H5P_FILE_ACCESS)))
HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, NULL, "not a file access property list")
- if(NULL == (fa = (H5FD_log_fapl_t *)H5P_get_driver_info(plist)))
+ if(NULL == (fa = (const H5FD_log_fapl_t *)H5P_peek_driver_info(plist)))
HGOTO_ERROR(H5E_PLIST, H5E_BADVALUE, NULL, "bad VFL driver info")
#ifdef H5_HAVE_GETTIMEOFDAY
@@ -922,7 +921,7 @@ H5FD_log_alloc(H5FD_t *_file, H5FD_mem_t type, hid_t H5_ATTR_UNUSED dxpl_id, hsi
{
H5FD_log_t *file = (H5FD_log_t *)_file;
haddr_t addr;
- haddr_t ret_value; /* Return value */
+ haddr_t ret_value = HADDR_UNDEF; /* Return value */
FUNC_ENTER_NOAPI_NOINIT_NOERR