diff options
Diffstat (limited to 'tools/h5repack/h5repack.c')
-rw-r--r-- | tools/h5repack/h5repack.c | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/tools/h5repack/h5repack.c b/tools/h5repack/h5repack.c index a5fb47f..3b00327 100644 --- a/tools/h5repack/h5repack.c +++ b/tools/h5repack/h5repack.c @@ -90,7 +90,7 @@ int h5repack_init(pack_opt_t *options, int verbose, H5F_file_space_type_t strategy, hsize_t threshold) { int k, n; - memset(options,0,sizeof(pack_opt_t)); + HDmemset(options,0,sizeof(pack_opt_t)); options->min_comp = 1024; options->verbose = verbose; @@ -157,7 +157,7 @@ int h5repack_addfilter(const char* str, if(options->n_filter_g > H5_REPACK_MAX_NFILTERS) { error_msg("maximum number of filters exceeded for <%s>\n", str); - free(obj_list); + HDfree(obj_list); return -1; } @@ -166,7 +166,7 @@ int h5repack_addfilter(const char* str, else options_add_filter(obj_list, n_objs, filter, options->op_tbl); - free(obj_list); + HDfree(obj_list); return 0; } @@ -232,7 +232,7 @@ int h5repack_addlayout(const char* str, &pack, options->op_tbl); - free(obj_list); + HDfree(obj_list); return 0; } @@ -493,24 +493,24 @@ int copy_attr(hid_t loc_in, type_class = H5Tget_class(wtype_id); is_ref = (type_class == H5T_REFERENCE); if (type_class == H5T_VLEN ||type_class == H5T_ARRAY ) { - hid_t base_type = -1; - base_type = H5Tget_super(ftype_id); - is_ref = (is_ref || (H5Tget_class(base_type)==H5T_REFERENCE)); - H5Tclose(base_type); + hid_t base_type = -1; + base_type = H5Tget_super(ftype_id); + is_ref = (is_ref || (H5Tget_class(base_type)==H5T_REFERENCE)); + H5Tclose(base_type); } if (type_class == H5T_COMPOUND) { - int nmembers = H5Tget_nmembers(wtype_id) ; - for (j=0; j<nmembers; j++) { - hid_t mtid = H5Tget_member_type( wtype_id, j ); - H5T_class_t mtclass = H5Tget_class(mtid); - H5Tclose(mtid); - - if (mtclass==H5T_REFERENCE) { - is_ref = 1; - break; - } - } /* for (j=0; i<nmembers; j++) */ + int nmembers = H5Tget_nmembers(wtype_id) ; + for (j=0; j<nmembers; j++) { + hid_t mtid = H5Tget_member_type( wtype_id, j ); + H5T_class_t mtclass = H5Tget_class(mtid); + H5Tclose(mtid); + + if (mtclass==H5T_REFERENCE) { + is_ref = 1; + break; + } + } /* for (j=0; i<nmembers; j++) */ } /* if (type_class == H5T_COMPOUND) */ if(is_ref) { |