diff options
author | Mohamad Chaarawi <chaarawi@hdfgroup.org> | 2012-03-14 14:48:34 (GMT) |
---|---|---|
committer | Mohamad Chaarawi <chaarawi@hdfgroup.org> | 2012-03-14 14:48:34 (GMT) |
commit | 10dd81d6bf70d17a573f8202fbf375e6badd18b3 (patch) | |
tree | dc8c626c4b33101b3e83d383bb606258cb0d061b /src/H5VL.c | |
parent | 6d61d2b0d017ebff61407a1816c5fcf7c0c8c7b9 (diff) | |
download | hdf5-10dd81d6bf70d17a573f8202fbf375e6badd18b3.zip hdf5-10dd81d6bf70d17a573f8202fbf375e6badd18b3.tar.gz hdf5-10dd81d6bf70d17a573f8202fbf375e6badd18b3.tar.bz2 |
[svn-r22065] fix a typo
forget to update the renamed functions in the header file
Diffstat (limited to 'src/H5VL.c')
-rw-r--r-- | src/H5VL.c | 12 |
1 files changed, 12 insertions, 0 deletions
@@ -557,6 +557,10 @@ H5VL_file_open(const char *name, unsigned flags, hid_t fcpl_id, hid_t fapl_id, h uid_info->obj_id = file_id; uid_info->vol_id = plugin_id; + /* increment ref count on the VOL id */ + if(H5I_inc_ref(uid_info->vol_id, FALSE) < 0) + HGOTO_ERROR(H5E_FILE, H5E_CANTINC, FAIL, "unable to increment ref count on vol plugin") + if((ret_value = H5I_register(H5I_UID, uid_info, TRUE)) < 0) HGOTO_ERROR(H5E_ATOM, H5E_CANTREGISTER, FAIL, "unable to atomize file handle") done: @@ -614,6 +618,10 @@ H5VL_file_create(const char *name, unsigned flags, hid_t fcpl_id, hid_t fapl_id) uid_info->obj_id = file_id; uid_info->vol_id = plugin_id; + /* increment ref count on the VOL id */ + if(H5I_inc_ref(uid_info->vol_id, FALSE) < 0) + HGOTO_ERROR(H5E_FILE, H5E_CANTINC, FAIL, "unable to increment ref count on vol plugin") + if((ret_value = H5I_register(H5I_UID, uid_info, TRUE)) < 0) HGOTO_ERROR(H5E_ATOM, H5E_CANTREGISTER, FAIL, "unable to atomize file handle") @@ -662,6 +670,10 @@ H5VL_file_close(hid_t uid) if((ret_value = (vol_plugin->file_cls.close)(uid_info->obj_id)) < 0) HGOTO_ERROR(H5E_VOL, H5E_CANTCLOSEFILE, FAIL, "close failed") + /* decrement ref count on the VOL id */ + if(H5I_dec_ref(uid_info->vol_id) < 0) + HGOTO_ERROR(H5E_FILE, H5E_CANTDEC, FAIL, "unable to decrement ref count on vol plugin") + if(H5I_dec_app_ref(uid) < 0) HGOTO_ERROR(H5E_FILE, H5E_CANTINC, FAIL, "unable to decrement ref count on user ID") done: |