mirror of
https://github.com/Unidata/netcdf-c.git
synced 2024-11-27 07:30:33 +08:00
Merge branch 'NCF-324' of https://github.com/qkoziol/netcdf-c into qkoziol-NCF-324
This commit is contained in:
commit
e2a56efa9c
@ -519,12 +519,11 @@ nc4_put_vara(NC *nc, int ncid, int varid, const size_t *startp,
|
||||
NC_HDF5_FILE_INFO_T *h5;
|
||||
NC_VAR_INFO_T *var;
|
||||
NC_DIM_INFO_T *dim;
|
||||
|
||||
hid_t file_spaceid = 0, mem_spaceid = 0, xfer_plistid = 0;
|
||||
|
||||
hsize_t xtend_size[NC_MAX_VAR_DIMS] , count[NC_MAX_VAR_DIMS];
|
||||
hsize_t fdims[NC_MAX_VAR_DIMS], fmaxdims[NC_MAX_VAR_DIMS];
|
||||
hsize_t start[NC_MAX_VAR_DIMS];
|
||||
char *name_to_use;
|
||||
int need_to_extend = 0;
|
||||
int retval = NC_NOERR, range_error = 0, i, d2;
|
||||
void *bufr = NULL;
|
||||
@ -564,12 +563,11 @@ nc4_put_vara(NC *nc, int ncid, int varid, const size_t *startp,
|
||||
if (var->hdf5_name && strlen(var->hdf5_name) >= strlen(NON_COORD_PREPEND) &&
|
||||
strncmp(var->hdf5_name, NON_COORD_PREPEND, strlen(NON_COORD_PREPEND)) == 0 &&
|
||||
var->ndims)
|
||||
if ((var->hdf_datasetid = H5Dopen2(grp->hdf_grpid, var->hdf5_name,
|
||||
H5P_DEFAULT)) < 0)
|
||||
return NC_ENOTVAR;
|
||||
name_to_use = var->hdf5_name;
|
||||
else
|
||||
name_to_use = var->name;
|
||||
if (!var->hdf_datasetid)
|
||||
if ((var->hdf_datasetid = H5Dopen2(grp->hdf_grpid, var->name,
|
||||
H5P_DEFAULT)) < 0)
|
||||
if ((var->hdf_datasetid = H5Dopen2(grp->hdf_grpid, name_to_use, H5P_DEFAULT)) < 0)
|
||||
return NC_ENOTVAR;
|
||||
|
||||
/* Get file space of data. */
|
||||
@ -845,14 +843,13 @@ nc4_get_vara(NC *nc, int ncid, int varid, const size_t *startp,
|
||||
NC_HDF5_FILE_INFO_T *h5;
|
||||
NC_VAR_INFO_T *var;
|
||||
NC_DIM_INFO_T *dim;
|
||||
|
||||
hid_t file_spaceid = 0, mem_spaceid = 0;
|
||||
hid_t xfer_plistid = 0;
|
||||
size_t file_type_size;
|
||||
|
||||
hsize_t *xtend_size = NULL, count[NC_MAX_VAR_DIMS];
|
||||
hsize_t fdims[NC_MAX_VAR_DIMS], fmaxdims[NC_MAX_VAR_DIMS];
|
||||
hsize_t start[NC_MAX_VAR_DIMS];
|
||||
char *name_to_use;
|
||||
void *fillvalue = NULL;
|
||||
int no_read = 0, provide_fill = 0;
|
||||
int fill_value_size[NC_MAX_VAR_DIMS];
|
||||
@ -893,12 +890,11 @@ nc4_get_vara(NC *nc, int ncid, int varid, const size_t *startp,
|
||||
if (var->hdf5_name && strlen(var->hdf5_name) >= strlen(NON_COORD_PREPEND) &&
|
||||
strncmp(var->hdf5_name, NON_COORD_PREPEND, strlen(NON_COORD_PREPEND)) == 0 &&
|
||||
var->ndims)
|
||||
if ((var->hdf_datasetid = H5Dopen2(grp->hdf_grpid, var->hdf5_name,
|
||||
H5P_DEFAULT)) < 0)
|
||||
return NC_ENOTVAR;
|
||||
name_to_use = var->hdf5_name;
|
||||
else
|
||||
name_to_use = var->name;
|
||||
if (!var->hdf_datasetid)
|
||||
if ((var->hdf_datasetid = H5Dopen2(grp->hdf_grpid, var->name,
|
||||
H5P_DEFAULT)) < 0)
|
||||
if ((var->hdf_datasetid = H5Dopen2(grp->hdf_grpid, name_to_use, H5P_DEFAULT)) < 0)
|
||||
return NC_ENOTVAR;
|
||||
|
||||
/* Get file space of data. */
|
||||
|
@ -42,13 +42,14 @@ if USE_NETCDF4
|
||||
check_PROGRAMS += tst_create_files tst_h_rdc0 tst_group_data \
|
||||
tst_enum_data tst_opaque_data tst_string_data tst_vlen_data tst_comp \
|
||||
tst_comp2 tst_nans tst_special_atts tst_unicode tst_fillbug tst_compress \
|
||||
tst_chunking tst_h_scalar
|
||||
tst_chunking tst_h_scalar tst_bug324
|
||||
|
||||
TESTS += tst_create_files tst_group_data tst_enum_data tst_opaque_data \
|
||||
tst_string_data tst_vlen_data tst_comp tst_comp2 tst_nans \
|
||||
tst_special_atts tst_netcdf4.sh tst_h_rdc0 tst_unicode tst_fillbug \
|
||||
tst_fillbug.sh tst_netcdf4_4.sh tst_compress tst_nccopy4.sh \
|
||||
tst_grp_spec.sh tst_mud.sh tst_h_scalar tst_h_scalar.sh tst_formatx4.sh
|
||||
tst_grp_spec.sh tst_mud.sh tst_h_scalar tst_h_scalar.sh tst_formatx4.sh \
|
||||
tst_bug324
|
||||
|
||||
if EXTRA_TESTS
|
||||
TESTS += run_back_comp_tests.sh
|
||||
|
Loading…
Reference in New Issue
Block a user