diff options
author | Neil Fortner <nfortne2@hdfgroup.org> | 2008-10-07 03:47:56 (GMT) |
---|---|---|
committer | Neil Fortner <nfortne2@hdfgroup.org> | 2008-10-07 03:47:56 (GMT) |
commit | a858608a0aa4ff6b23e35e210da3e7b2d461df51 (patch) | |
tree | b128cbc269926fb7b133476ef08a6a7f2d494b15 /src/H5Oattribute.c | |
parent | d7437bc5b171fef226813a576dea088d00f67b9a (diff) | |
download | hdf5-a858608a0aa4ff6b23e35e210da3e7b2d461df51.zip hdf5-a858608a0aa4ff6b23e35e210da3e7b2d461df51.tar.gz hdf5-a858608a0aa4ff6b23e35e210da3e7b2d461df51.tar.bz2 |
[svn-r15797] Purpose: Close bug #1322
Description: Fixes a possible datatype id leak that could occur during compound
datatype conversion, or more precisely, when unregistering those conversions.
Datatype ids normally registered by the library are no longer visible to the
application via H5Fget_obj_ids and H5Fget_obj_count.
Tested: kagiso, linew, smirom (h5committest)
Diffstat (limited to 'src/H5Oattribute.c')
-rw-r--r-- | src/H5Oattribute.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/H5Oattribute.c b/src/H5Oattribute.c index a0d807c..466d691 100644 --- a/src/H5Oattribute.c +++ b/src/H5Oattribute.c @@ -684,7 +684,7 @@ htri_t H5O_attr_find_opened_attr(const H5O_loc_t *loc, H5A_t **attr, const char* HGOTO_ERROR(H5E_ATTR, H5E_BADVALUE, FAIL, "can't get file serial number") /* Count all opened attributes */ - if((num_open_attr = H5F_get_obj_count(loc->file, H5F_OBJ_ATTR | H5F_OBJ_LOCAL)) < 0) + if((num_open_attr = H5F_get_obj_count(loc->file, H5F_OBJ_ATTR | H5F_OBJ_LOCAL, FALSE)) < 0) HGOTO_ERROR(H5E_ATTR, H5E_CANTCOUNT, FAIL, "can't get number of opened attributes") /* Find out whether the attribute has been opened */ @@ -692,7 +692,7 @@ htri_t H5O_attr_find_opened_attr(const H5O_loc_t *loc, H5A_t **attr, const char* attr_id_list = (hid_t*)H5MM_malloc(num_open_attr*sizeof(hid_t)); /* Retrieve the IDs of all opened attributes */ - if(H5F_get_obj_ids(loc->file, H5F_OBJ_ATTR | H5F_OBJ_LOCAL, num_open_attr, attr_id_list) < 0) + if(H5F_get_obj_ids(loc->file, H5F_OBJ_ATTR | H5F_OBJ_LOCAL, num_open_attr, attr_id_list, FALSE) < 0) HGOTO_ERROR(H5E_ATTR, H5E_CANTGET, FAIL, "can't IDs of opened attributes") for(i=0; i<num_open_attr; i++) { |