summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/H5B2int.c4
-rw-r--r--src/H5Bdbg.c4
-rw-r--r--src/H5Gint.c11
-rw-r--r--src/H5HFtiny.c2
-rw-r--r--src/H5Oattr.c2
-rw-r--r--src/H5Ocache.c14
-rw-r--r--src/H5Ofill.c4
-rw-r--r--src/H5Olink.c2
-rw-r--r--src/H5SL.c2
-rwxr-xr-xsrc/H5SM.c2
-rw-r--r--src/H5SMcache.c2
-rw-r--r--src/H5T.c4
-rw-r--r--src/H5Zscaleoffset.c6
13 files changed, 32 insertions, 27 deletions
diff --git a/src/H5B2int.c b/src/H5B2int.c
index f0213ce..550a5b6 100644
--- a/src/H5B2int.c
+++ b/src/H5B2int.c
@@ -3211,8 +3211,6 @@ done:
static herr_t
H5B2_assert_leaf(H5B2_shared_t *shared, H5B2_leaf_t *leaf)
{
- unsigned u,v; /* Local index variables */
-
/* General sanity checking on node */
HDassert(leaf->nrec<=shared->node_info->split_nrec);
@@ -3236,8 +3234,6 @@ H5B2_assert_leaf(H5B2_shared_t *shared, H5B2_leaf_t *leaf)
static herr_t
H5B2_assert_leaf2(H5B2_shared_t *shared, H5B2_leaf_t *leaf, H5B2_leaf_t *leaf2)
{
- unsigned u,v; /* Local index variables */
-
/* General sanity checking on node */
HDassert(leaf->nrec<=shared->node_info->split_nrec);
diff --git a/src/H5Bdbg.c b/src/H5Bdbg.c
index f517daf..c31b4c3 100644
--- a/src/H5Bdbg.c
+++ b/src/H5Bdbg.c
@@ -36,6 +36,7 @@
#include "H5private.h" /* Generic Functions */
#include "H5Bpkg.h" /* B-link trees */
#include "H5Eprivate.h" /* Error handling */
+#include "H5MMprivate.h" /* Memory management */
/*-------------------------------------------------------------------------
@@ -190,7 +191,7 @@ H5B_assert(H5F_t *f, hid_t dxpl_id, haddr_t addr, const H5B_class_t *type, void
struct child_t *next;
} *head = NULL, *tail = NULL, *prev = NULL, *cur = NULL, *tmp = NULL;
- FUNC_ENTER_NOAPI(H5B_assert, FAIL)
+ FUNC_ENTER_NOAPI_NOFUNC(H5B_assert)
if (0==ncalls++) {
if (H5DEBUG(B)) {
@@ -277,7 +278,6 @@ H5B_assert(H5F_t *f, hid_t dxpl_id, haddr_t addr, const H5B_class_t *type, void
head = tmp;
}
-done:
FUNC_LEAVE_NOAPI(ret_value)
}
#endif /* H5B_DEBUG */
diff --git a/src/H5Gint.c b/src/H5Gint.c
index 61598c2..0dc9c03 100644
--- a/src/H5Gint.c
+++ b/src/H5Gint.c
@@ -94,9 +94,16 @@ DESCRIPTION
static herr_t
H5G_init_int_interface(void)
{
- FUNC_ENTER_NOAPI_NOINIT_NOFUNC(H5G_init_int_interface)
+ herr_t ret_value = SUCCEED; /* Return value */
- FUNC_LEAVE_NOAPI(H5G_init())
+ FUNC_ENTER_NOAPI(H5G_init_int_interface, FAIL)
+
+ /* Funnel all work to H5G_init() */
+ if(H5G_init() < 0)
+ HGOTO_ERROR(H5E_FUNC, H5E_CANTINIT, FAIL, "interface initialization failed")
+
+done:
+ FUNC_LEAVE_NOAPI(ret_value)
} /* H5G_init_int_interface() */
diff --git a/src/H5HFtiny.c b/src/H5HFtiny.c
index 5f5b295..ce91bd1 100644
--- a/src/H5HFtiny.c
+++ b/src/H5HFtiny.c
@@ -291,7 +291,7 @@ H5HF_tiny_op_real(H5HF_hdr_t *hdr, const uint8_t *id, H5HF_operator_t op,
HGOTO_ERROR(H5E_HEAP, H5E_CANTOPERATE, FAIL, "application's callback failed")
done:
- FUNC_LEAVE_NOAPI(SUCCEED)
+ FUNC_LEAVE_NOAPI(ret_value)
} /* end H5HF_tiny_op_real() */
diff --git a/src/H5Oattr.c b/src/H5Oattr.c
index c474681..971c514 100644
--- a/src/H5Oattr.c
+++ b/src/H5Oattr.c
@@ -171,7 +171,7 @@ H5O_attr_decode(H5F_t *f, hid_t dxpl_id, H5O_t *open_oh, unsigned UNUSED mesg_fl
* as well as some reserved bytes.
*/
if(attr->shared->version >= H5O_ATTR_VERSION_3)
- attr->shared->encoding = *p++;
+ attr->shared->encoding = (H5T_cset_t)*p++;
/* Decode and store the name */
if(NULL == (attr->shared->name = H5MM_strdup((const char *)p)))
diff --git a/src/H5Ocache.c b/src/H5Ocache.c
index 6c86681..d396896 100644
--- a/src/H5Ocache.c
+++ b/src/H5Ocache.c
@@ -187,10 +187,16 @@ H5O_load(H5F_t *f, hid_t dxpl_id, haddr_t addr, const void UNUSED * _udata1,
/* Time fields */
if(oh->flags & H5O_HDR_STORE_TIMES) {
- UINT32DECODE(p, oh->atime);
- UINT32DECODE(p, oh->mtime);
- UINT32DECODE(p, oh->ctime);
- UINT32DECODE(p, oh->btime);
+ uint32_t tmp; /* Temporary value */
+
+ UINT32DECODE(p, tmp);
+ oh->atime = (time_t)tmp;
+ UINT32DECODE(p, tmp);
+ oh->mtime = (time_t)tmp;
+ UINT32DECODE(p, tmp);
+ oh->ctime = (time_t)tmp;
+ UINT32DECODE(p, tmp);
+ oh->btime = (time_t)tmp;
} /* end if */
else
oh->atime = oh->mtime = oh->ctime = oh->btime = 0;
diff --git a/src/H5Ofill.c b/src/H5Ofill.c
index d5345aa..8cf901f 100644
--- a/src/H5Ofill.c
+++ b/src/H5Ofill.c
@@ -236,10 +236,10 @@ H5O_fill_new_decode(H5F_t UNUSED *f, hid_t UNUSED dxpl_id, H5O_t UNUSED *open_oh
HGOTO_ERROR(H5E_OHDR, H5E_CANTLOAD, NULL, "unknown flag for fill value message")
/* Space allocation time */
- fill->alloc_time = (flags >> H5O_FILL_SHIFT_ALLOC_TIME) & H5O_FILL_MASK_ALLOC_TIME;
+ fill->alloc_time = (H5D_alloc_time_t)((flags >> H5O_FILL_SHIFT_ALLOC_TIME) & H5O_FILL_MASK_ALLOC_TIME);
/* Fill value write time */
- fill->fill_time = (flags >> H5O_FILL_SHIFT_FILL_TIME) & H5O_FILL_MASK_FILL_TIME;
+ fill->fill_time = (H5D_fill_time_t)((flags >> H5O_FILL_SHIFT_FILL_TIME) & H5O_FILL_MASK_FILL_TIME);
/* Check for undefined fill value */
if(flags & H5O_FILL_FLAG_UNDEFINED_VALUE) {
diff --git a/src/H5Olink.c b/src/H5Olink.c
index 96d4747..ffe80e7 100644
--- a/src/H5Olink.c
+++ b/src/H5Olink.c
@@ -146,7 +146,7 @@ H5O_link_decode(H5F_t *f, hid_t UNUSED dxpl_id, H5O_t UNUSED *open_oh,
/* Check for non-default link type */
if(link_flags & H5O_LINK_STORE_LINK_TYPE) {
/* Get the type of the link */
- lnk->type = *p++;
+ lnk->type = (H5L_type_t)*p++;
if(lnk->type < H5L_TYPE_HARD || lnk->type > H5L_TYPE_MAX)
HGOTO_ERROR(H5E_OHDR, H5E_CANTLOAD, NULL, "bad link type")
} /* end if */
diff --git a/src/H5SL.c b/src/H5SL.c
index 31e81c2..d28e5be 100644
--- a/src/H5SL.c
+++ b/src/H5SL.c
@@ -2167,7 +2167,7 @@ int H5SL_term_interface(void)
H5SL_fac_nused_g = 0;
/* Free the list of factories */
- H5SL_fac_g = (H5FL_reg_head_t **)H5MM_xfree((void *)H5SL_fac_g);
+ H5SL_fac_g = (H5FL_fac_head_t **)H5MM_xfree((void *)H5SL_fac_g);
H5SL_fac_nalloc_g = 0;
/* Mark the interface as uninitialized */
diff --git a/src/H5SM.c b/src/H5SM.c
index c383877..2153d79 100755
--- a/src/H5SM.c
+++ b/src/H5SM.c
@@ -1911,7 +1911,7 @@ H5SM_message_decode(const H5F_t UNUSED *f, const uint8_t *raw, void *_nrecord)
FUNC_ENTER_NOAPI_NOINIT_NOFUNC(H5SM_message_decode)
- message->location = *raw++;
+ message->location = (H5SM_storage_loc_t)*raw++;
UINT32DECODE(raw, message->hash);
if(message->location == H5SM_IN_HEAP) {
diff --git a/src/H5SMcache.c b/src/H5SMcache.c
index d53993e..e2aa732 100644
--- a/src/H5SMcache.c
+++ b/src/H5SMcache.c
@@ -188,7 +188,7 @@ H5SM_table_load(H5F_t *f, hid_t dxpl_id, haddr_t addr, const void UNUSED *udata1
HGOTO_ERROR(H5E_FILE, H5E_VERSION, NULL, "bad shared message list version number")
/* Type of the index (list or B-tree) */
- table->indexes[x].index_type= *p++;
+ table->indexes[x].index_type= (H5SM_index_type_t)*p++;
/* Type of messages in the index */
UINT16DECODE(p, table->indexes[x].mesg_types);
diff --git a/src/H5T.c b/src/H5T.c
index 4dd1984..4b710d3 100644
--- a/src/H5T.c
+++ b/src/H5T.c
@@ -720,10 +720,8 @@ H5T_init_interface(void)
H5T_t *std_u16be=NULL; /* Datatype structure for unsigned 16-bit big-endian integer */
H5T_t *std_u32le=NULL; /* Datatype structure for unsigned 32-bit little-endian integer */
H5T_t *std_u32be=NULL; /* Datatype structure for unsigned 32-bit big-endian integer */
- H5T_t *std_i32le=NULL; /* Datatype structure for signed 32-bit little-endian integer */
H5T_t *std_u64le=NULL; /* Datatype structure for unsigned 64-bit little-endian integer */
H5T_t *std_u64be=NULL; /* Datatype structure for unsigned 64-bit big-endian integer */
- H5T_t *ieee_f64le=NULL; /* Datatype structure for IEEE 64-bit little-endian floating-point */
H5T_t *dt = NULL;
H5T_t *fixedpt=NULL; /* Datatype structure for native int */
H5T_t *floatpt=NULL; /* Datatype structure for native float */
@@ -836,7 +834,6 @@ H5T_init_interface(void)
/* IEEE 8-byte little-endian float */
H5T_INIT_TYPE(DOUBLELE,H5T_IEEE_F64LE_g,COPY,native_double,SET,8)
- ieee_f64le=dt; /* Keep type for later */
/* IEEE 8-byte big-endian float */
H5T_INIT_TYPE(DOUBLEBE,H5T_IEEE_F64BE_g,COPY,native_double,SET,8)
@@ -871,7 +868,6 @@ H5T_init_interface(void)
/* 4-byte little-endian signed integer */
H5T_INIT_TYPE(SINTLE,H5T_STD_I32LE_g,COPY,native_int,SET,4)
- std_i32le=dt; /* Keep type for later */
/* 4-byte big-endian signed integer */
H5T_INIT_TYPE(SINTBE,H5T_STD_I32BE_g,COPY,native_int,SET,4)
diff --git a/src/H5Zscaleoffset.c b/src/H5Zscaleoffset.c
index d59499c..8e32ab7 100644
--- a/src/H5Zscaleoffset.c
+++ b/src/H5Zscaleoffset.c
@@ -916,7 +916,7 @@ H5Z_filter_scaleoffset (unsigned flags, size_t cd_nelmts, const unsigned cd_valu
unsigned dtype_class; /* datatype class */
unsigned dtype_sign; /* integer datatype sign */
unsigned filavail; /* flag indicating if fill value is defined or not */
- H5Z_SO_scale_type_t scale_type = 0;/* scale type */
+ H5Z_SO_scale_type_t scale_type = H5Z_SO_FLOAT_DSCALE;/* scale type */
int scale_factor = 0; /* scale factor */
double D_val = 0.0; /* decimal scale factor */
uint32_t minbits = 0; /* minimum number of bits to store values */
@@ -955,8 +955,8 @@ H5Z_filter_scaleoffset (unsigned flags, size_t cd_nelmts, const unsigned cd_valu
dtype_class = cd_values[H5Z_SCALEOFFSET_PARM_CLASS];
dtype_sign = cd_values[H5Z_SCALEOFFSET_PARM_SIGN];
filavail = cd_values[H5Z_SCALEOFFSET_PARM_FILAVAIL];
- scale_factor = (int) cd_values[H5Z_SCALEOFFSET_PARM_SCALEFACTOR];
- scale_type = cd_values[H5Z_SCALEOFFSET_PARM_SCALETYPE];
+ scale_factor = (int)cd_values[H5Z_SCALEOFFSET_PARM_SCALEFACTOR];
+ scale_type = (H5Z_SO_scale_type_t)cd_values[H5Z_SCALEOFFSET_PARM_SCALETYPE];
/* check and assign proper values set by user to related parameters
* scale type can be H5Z_SO_FLOAT_DSCALE (0), H5Z_SO_FLOAT_ESCALE (1) or H5Z_SO_INT (other)