diff --git a/src/h5core/h5_hsearch.c b/src/h5core/h5_hsearch.c index 63e781f..2ee5554 100644 --- a/src/h5core/h5_hsearch.c +++ b/src/h5core/h5_hsearch.c @@ -213,7 +213,7 @@ h5priv_hsearch ( if (htab->table[idx].used == hval && ((*htab->compare) ( item, htab->table[idx].entry) == 0) ) { - if (retval && *retval) { + if (retval) { *retval = htab->table[idx].entry; } return H5_SUCCESS; @@ -238,7 +238,7 @@ h5priv_hsearch ( ++htab->filled; - if (retval && *retval) { + if (retval) { *retval = htab->table[idx].entry; } return H5_SUCCESS; diff --git a/src/h5core/h5t_retrieve.c b/src/h5core/h5t_retrieve.c index be7c9d3..8150fd7 100644 --- a/src/h5core/h5t_retrieve.c +++ b/src/h5core/h5t_retrieve.c @@ -208,6 +208,7 @@ h5t_init_leaf_iterator ( } else if (it->codim == 0) { it->iter = iterate_leaf_elems; } + TRY2( h5tpriv_init_entity_iterator (f, iter, codim) ); H5_CORE_API_RETURN (h5err); } @@ -219,7 +220,7 @@ h5t_init_boundary_face_iterator ( ) { H5_CORE_API_ENTER; h5_err_t h5err = H5_SUCCESS; - h5t_leaf_iterator_t* it; + h5t_leaf_iterator_t* it = (h5t_leaf_iterator_t*)iter; it->face_idx = 999; // something > max number of faces it->elem_idx = -1; it->codim = codim;