summaryrefslogtreecommitdiffstats
path: root/src/H5F.c
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2000-04-15 20:28:12 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2000-04-15 20:28:12 (GMT)
commit2ec6fd667bb4c49539bb820cb2b6f426e6c4c10a (patch)
tree77e150c8e92dcc45e759cf1addc5d3b103401a32 /src/H5F.c
parentf12e3316665d7ac89820cc9ccecfad8e5537ce44 (diff)
downloadhdf5-2ec6fd667bb4c49539bb820cb2b6f426e6c4c10a.zip
hdf5-2ec6fd667bb4c49539bb820cb2b6f426e6c4c10a.tar.gz
hdf5-2ec6fd667bb4c49539bb820cb2b6f426e6c4c10a.tar.bz2
[svn-r2151] Modified H5_term_library to not reported errors when H5Eset_auto(NULL,NULL)
has turned off error reporting in the library. Also, changed the way property lists are managed and closed so that they can be automatically closed when the library terminates.
Diffstat (limited to 'src/H5F.c')
-rw-r--r--src/H5F.c21
1 files changed, 11 insertions, 10 deletions
diff --git a/src/H5F.c b/src/H5F.c
index b15f3fc..eb60325 100644
--- a/src/H5F.c
+++ b/src/H5F.c
@@ -432,7 +432,7 @@ H5Fget_create_plist(hid_t file_id)
{
H5F_t *file = NULL;
hid_t ret_value = FAIL;
- H5F_create_t *plist = NULL;
+ H5P_t *plist = NULL;
FUNC_ENTER(H5Fget_create_plist, FAIL);
H5TRACE1("i","i",file_id);
@@ -450,8 +450,8 @@ H5Fget_create_plist(hid_t file_id)
/* Create an atom */
if ((ret_value = H5P_create(H5P_FILE_CREATE, plist)) < 0) {
- H5P_close(H5P_FILE_CREATE, plist);
- HRETURN_ERROR(H5E_ATOM, H5E_CANTREGISTER, FAIL,
+ H5P_close(plist);
+ HRETURN_ERROR(H5E_ATOM, H5E_CANTREGISTER, FAIL,
"unable to register property list");
}
@@ -481,7 +481,8 @@ hid_t
H5Fget_access_plist(hid_t file_id)
{
H5F_t *f = NULL;
- H5F_access_t *fapl=NULL, _fapl;
+ H5F_access_t _fapl;
+ H5P_t *plist=NULL;
hid_t ret_value = FAIL;
FUNC_ENTER(H5Fget_access_plist, FAIL);
@@ -505,18 +506,18 @@ H5Fget_access_plist(hid_t file_id)
_fapl.driver_info = NULL; /*just for now */
/* Copy properties */
- if (NULL==(fapl=H5P_copy(H5P_FILE_ACCESS, &_fapl))) {
+ if (NULL==(plist=H5P_copy(H5P_FILE_ACCESS, &_fapl))) {
HRETURN_ERROR(H5E_INTERNAL, H5E_CANTINIT, FAIL,
"unable to copy file access properties");
}
/* Get the properties for the file driver */
- fapl->driver_info = H5FD_fapl_get(f->shared->lf);
+ plist->u.faccess.driver_info = H5FD_fapl_get(f->shared->lf);
/* Create an atom */
- if ((ret_value = H5P_create(H5P_FILE_ACCESS, fapl))<0) {
- H5P_close(H5P_FILE_ACCESS, fapl);
- HRETURN_ERROR(H5E_ATOM, H5E_CANTREGISTER, FAIL,
+ if ((ret_value = H5P_create(H5P_FILE_ACCESS, plist))<0) {
+ H5P_close(plist);
+ HRETURN_ERROR(H5E_ATOM, H5E_CANTREGISTER, FAIL,
"unable to register property list");
}
@@ -834,7 +835,7 @@ H5F_dest(H5F_t *f)
f->shared->cwfs = H5MM_xfree (f->shared->cwfs);
/* Destroy file creation properties */
- H5P_close(H5P_FILE_CREATE, f->shared->fcpl);
+ H5P_close(f->shared->fcpl);
/* Destroy shared file struct */
if (H5FD_close(f->shared->lf)<0) {