diff options
author | Raymond Lu <songyulu@hdfgroup.org> | 2004-06-11 20:18:43 (GMT) |
---|---|---|
committer | Raymond Lu <songyulu@hdfgroup.org> | 2004-06-11 20:18:43 (GMT) |
commit | ea3103c15ecddf752e23e63bcad6d1da13912619 (patch) | |
tree | 592fa7ca51545e6cb2c15b2876aa9af91b7dd0e0 /src/H5Tcommit.c | |
parent | 2194263d1b88b2bc585920e0764149431bde97df (diff) | |
download | hdf5-ea3103c15ecddf752e23e63bcad6d1da13912619.zip hdf5-ea3103c15ecddf752e23e63bcad6d1da13912619.tar.gz hdf5-ea3103c15ecddf752e23e63bcad6d1da13912619.tar.bz2 |
[svn-r8661] Purpose: Add comments.
Description: More comments to clarify action.
Platforms tested: No code change, no test.
Diffstat (limited to 'src/H5Tcommit.c')
-rw-r--r-- | src/H5Tcommit.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/H5Tcommit.c b/src/H5Tcommit.c index 3a3b7a1..757bb8c 100644 --- a/src/H5Tcommit.c +++ b/src/H5Tcommit.c @@ -148,7 +148,8 @@ H5T_commit (H5G_entry_t *loc, const char *name, H5T_t *type, hid_t dxpl_id) if(H5T_is_sensible(type)!=TRUE) HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "datatype is not sensible"); - /* Mark datatype as being on disk now */ + /* Mark datatype as being on disk now. This step changes the size of datatype as + * stored on disk. */ if(H5T_set_loc(type, file, H5T_LOC_DISK)<0) HGOTO_ERROR(H5E_DATATYPE, H5E_CANTINIT, FAIL, "cannot mark datatype on disk") @@ -164,7 +165,8 @@ H5T_commit (H5G_entry_t *loc, const char *name, H5T_t *type, hid_t dxpl_id) HGOTO_ERROR (H5E_DATATYPE, H5E_CANTINIT, FAIL, "unable to name data type"); type->state = H5T_STATE_OPEN; - /* Mark datatype as being on memory now */ + /* Mark datatype as being on memory now. Since this datatype may still be used in memory + * after committed to disk, change its size back as in memory. */ if(H5T_set_loc(type, NULL, H5T_LOC_MEMORY)<0) HGOTO_ERROR(H5E_DATATYPE, H5E_CANTINIT, FAIL, "cannot mark datatype in memory") |