mirror of
https://github.com/Unidata/netcdf-c.git
synced 2025-01-30 16:10:44 +08:00
change H5F_CLOSE_SEMI -> H5F_CLOSE_WEAK for nc4_create_file as well
The nc_sync test fails if the settings are different for file creation and opening.
This commit is contained in:
parent
9f8897762d
commit
a3b753d764
@ -121,11 +121,12 @@ nc4_create_file(const char *path, int cmode, size_t initialsz,
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* Need this access plist to control how HDF5 handles open objects
|
/* Need this access plist to control how HDF5 handles open objects
|
||||||
* on file close. Setting H5F_CLOSE_SEMI will cause H5Fclose to
|
* on file close. (Setting H5F_CLOSE_WEAK will cause H5Fclose not to
|
||||||
* fail if there are any open objects in the file. */
|
* fail if there are any open objects in the file. This may happen when virtual
|
||||||
|
* datasets are opened). */
|
||||||
if ((fapl_id = H5Pcreate(H5P_FILE_ACCESS)) < 0)
|
if ((fapl_id = H5Pcreate(H5P_FILE_ACCESS)) < 0)
|
||||||
BAIL(NC_EHDFERR);
|
BAIL(NC_EHDFERR);
|
||||||
if (H5Pset_fclose_degree(fapl_id, H5F_CLOSE_SEMI))
|
if (H5Pset_fclose_degree(fapl_id, H5F_CLOSE_WEAK))
|
||||||
BAIL(NC_EHDFERR);
|
BAIL(NC_EHDFERR);
|
||||||
|
|
||||||
#ifdef USE_PARALLEL4
|
#ifdef USE_PARALLEL4
|
||||||
|
Loading…
Reference in New Issue
Block a user