summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorNeil Fortner <nfortne2@hdfgroup.org>2015-08-20 16:38:05 (GMT)
committerNeil Fortner <nfortne2@hdfgroup.org>2015-08-20 16:38:05 (GMT)
commite3bea916863c05b93c1a9277edd7fb91c95805c2 (patch)
treeca288c2a4955ecbaa18a2a5a6ee6dde0e34207c1 /src
parentb1dcfc7a84e5e804c84426fc6fa10d323c7f3b24 (diff)
downloadhdf5-e3bea916863c05b93c1a9277edd7fb91c95805c2.zip
hdf5-e3bea916863c05b93c1a9277edd7fb91c95805c2.tar.gz
hdf5-e3bea916863c05b93c1a9277edd7fb91c95805c2.tar.bz2
[svn-r27538] Add tests to cover remaining code coverage assertions in src directory except
for those in H5Doh.c and H5Shyper.c. Tested: ummon
Diffstat (limited to 'src')
-rw-r--r--src/H5Dint.c1
-rw-r--r--src/H5Dvirtual.c9
-rw-r--r--src/H5Pdapl.c8
-rw-r--r--src/H5Pdcpl.c1
-rw-r--r--src/H5Sselect.c1
5 files changed, 4 insertions, 16 deletions
diff --git a/src/H5Dint.c b/src/H5Dint.c
index 490a3c5..97f4fc5 100644
--- a/src/H5Dint.c
+++ b/src/H5Dint.c
@@ -2056,7 +2056,6 @@ H5D__get_offset(const H5D_t *dset)
switch(dset->shared->layout.type) {
case H5D_VIRTUAL:
- HDassert(0 && "checking code coverage...");//VDSINC
case H5D_CHUNKED:
case H5D_COMPACT:
break;
diff --git a/src/H5Dvirtual.c b/src/H5Dvirtual.c
index 46255dd..10e53c9 100644
--- a/src/H5Dvirtual.c
+++ b/src/H5Dvirtual.c
@@ -1428,7 +1428,6 @@ H5D__virtual_set_extent_unlim(const H5D_t *dset, hid_t dxpl_id)
else {
H5O_storage_virtual_srcdset_t *tmp_sub_dset;
- HDassert(0 && "Checking code coverage..."); //VDSINC
/* Extend sub_dset */
if(NULL == (tmp_sub_dset = (H5O_storage_virtual_srcdset_t *)H5MM_realloc(storage->list[i].sub_dset, 2 * storage->list[i].sub_dset_nalloc * sizeof(H5O_storage_virtual_srcdset_t))))
HGOTO_ERROR(H5E_RESOURCE, H5E_CANTALLOC, FAIL, "unable to extend sub dataset array")
@@ -2648,10 +2647,8 @@ H5D__virtual_write(H5D_io_info_t *io_info, const H5D_type_info_t *type_info,
/* Fail if there are unmapped parts of the selection as they would not be
* written */
- if(tot_nelmts != nelmts) {
- HDassert(0 && "Checking code coverage..."); //VDSINC
+ if(tot_nelmts != nelmts)
HGOTO_ERROR(H5E_DATASPACE, H5E_BADVALUE, FAIL, "write requested to unmapped portion of virtual dataset")
- } //VDSINC
/* Iterate over mappings */
for(i = 0; i < storage->list_nused; i++) {
@@ -2662,11 +2659,9 @@ H5D__virtual_write(H5D_io_info_t *io_info, const H5D_type_info_t *type_info,
if(storage->list[i].psfn_nsubs || storage->list[i].psdn_nsubs) {
/* Iterate over sub-source dsets */
for(j = storage->list[i].sub_dset_io_start;
- j < storage->list[i].sub_dset_io_end; j++) {
- HDassert(0 && "Checking code coverage..."); //VDSINC
+ j < storage->list[i].sub_dset_io_end; j++)
if(H5D__virtual_write_one(io_info, type_info, file_space, &storage->list[i].sub_dset[j]) < 0)
HGOTO_ERROR(H5E_DATASET, H5E_WRITEERROR, FAIL, "unable to write to source dataset")
- } //VDSINC
} /* end if */
else
/* Write to source dataset */
diff --git a/src/H5Pdapl.c b/src/H5Pdapl.c
index b439009..5574fa9 100644
--- a/src/H5Pdapl.c
+++ b/src/H5Pdapl.c
@@ -379,11 +379,9 @@ H5Pget_virtual_view(hid_t plist_id, H5D_vds_view_t *view)
HGOTO_ERROR(H5E_ATOM, H5E_BADATOM, H5D_VDS_ERROR, "can't find object for ID")
/* Get value from property list */
- if(view) {
- HDassert(0 && "Checking code coverage..."); //VDSINC
+ if(view)
if(H5P_get(plist, H5D_ACS_VDS_VIEW_NAME, view) < 0)
HGOTO_ERROR(H5E_PLIST, H5E_CANTGET, H5D_VDS_ERROR, "unable to get value")
- } //VDSINC
done:
FUNC_LEAVE_API(ret_value)
@@ -525,11 +523,9 @@ H5Pget_virtual_printf_gap(hid_t plist_id, hsize_t *gap_size)
HGOTO_ERROR(H5E_ATOM, H5E_BADATOM, H5D_VDS_ERROR, "can't find object for ID")
/* Get value from property list */
- if(gap_size) {
- HDassert(0 && "Checking code coverage..."); //VDSINC
+ if(gap_size)
if(H5P_get(plist, H5D_ACS_VDS_PRINTF_GAP_NAME, gap_size) < 0)
HGOTO_ERROR(H5E_PLIST, H5E_CANTGET, H5D_VDS_ERROR, "unable to get value")
- } //VDSINC
done:
FUNC_LEAVE_API(ret_value)
diff --git a/src/H5Pdcpl.c b/src/H5Pdcpl.c
index b70004b..ebc3919 100644
--- a/src/H5Pdcpl.c
+++ b/src/H5Pdcpl.c
@@ -1868,7 +1868,6 @@ H5Pset_virtual(hid_t dcpl_id, hid_t vspace_id, const char *src_file_name,
} /* end if */
else if(layout.storage.u.virt.list_nused
== layout.storage.u.virt.list_nalloc) {
- HDassert((layout.storage.u.virt.list_nused > 0) && "checking code coverage...");//VDSINC
/* Double size of entry list. Make sure to zero out new memory. */
if(NULL == (layout.storage.u.virt.list = (H5O_storage_virtual_ent_t *)H5MM_realloc(layout.storage.u.virt.list, (size_t)2 * layout.storage.u.virt.list_nalloc * sizeof(H5O_storage_virtual_ent_t))))
HGOTO_ERROR(H5E_PLIST, H5E_RESOURCE, FAIL, "can't reallocate virtual dataset mapping list")
diff --git a/src/H5Sselect.c b/src/H5Sselect.c
index 86a8c43..e965dba 100644
--- a/src/H5Sselect.c
+++ b/src/H5Sselect.c
@@ -2350,7 +2350,6 @@ H5S_select_subtract(H5S_t *space, H5S_t *subtract_space)
&& (subtract_space->select.type->type != H5S_SEL_NONE)) {
/* If subtract_space is using the all selection, set space to none */
if(subtract_space->select.type->type == H5S_SEL_ALL) {
- HDassert(0 && "Checking code coverage...");//VDSINC
/* Change to "none" selection */
if(H5S_select_none(space) < 0)
HGOTO_ERROR(H5E_DATASPACE, H5E_CANTDELETE, FAIL, "can't change selection")