summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2002-08-09 15:39:28 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2002-08-09 15:39:28 (GMT)
commita7028fb006be7d91626650f22748d22a1a74f6ee (patch)
tree874020ca2742a30dcc7d311bc655dd1ecf621e27 /src
parent71d795f3efe63e329e28da7a405657471a55a3df (diff)
downloadhdf5-a7028fb006be7d91626650f22748d22a1a74f6ee.zip
hdf5-a7028fb006be7d91626650f22748d22a1a74f6ee.tar.gz
hdf5-a7028fb006be7d91626650f22748d22a1a74f6ee.tar.bz2
[svn-r5865] Purpose:
Bug fix Description: hsize_t comparisons for selection boundaries (in H5Sget_select_bounds) were failing on Linux with --disable-hsizet. Solution: Changed comparisons to use use unsigned values instead of signed ones. Platforms tested: Linux 2.2.x (eirene)
Diffstat (limited to 'src')
-rw-r--r--src/H5Shyper.c6
-rw-r--r--src/H5Spoint.c2
2 files changed, 4 insertions, 4 deletions
diff --git a/src/H5Shyper.c b/src/H5Shyper.c
index c286175..d69a073 100644
--- a/src/H5Shyper.c
+++ b/src/H5Shyper.c
@@ -2046,9 +2046,9 @@ H5S_hyper_bounds_helper (const H5S_hyper_span_info_t *spans, const hssize_t *off
curr=spans->head;
while(curr!=NULL) {
/* Check if the current span extends the bounding box */
- if((curr->low+offset[rank])<(hssize_t)start[rank])
+ if((hsize_t)(curr->low+offset[rank])<start[rank])
start[rank]=curr->low+offset[rank];
- if((curr->high+offset[rank])>(hssize_t)end[rank])
+ if((hsize_t)(curr->high+offset[rank])>end[rank])
end[rank]=curr->high+offset[rank];
/* Recurse if this node has down spans */
@@ -2109,7 +2109,7 @@ H5S_hyper_bounds(const H5S_t *space, hsize_t *start, hsize_t *end)
/* Set the start and end arrays up */
rank=space->extent.u.simple.rank;
for(i=0; i<rank; i++) {
- start[i]=UINT_MAX;
+ start[i]=HSIZET_MAX;
end[i]=0;
} /* end for */
diff --git a/src/H5Spoint.c b/src/H5Spoint.c
index 6e6ca5b..786eae3 100644
--- a/src/H5Spoint.c
+++ b/src/H5Spoint.c
@@ -884,7 +884,7 @@ H5S_point_bounds(const H5S_t *space, hsize_t *start, hsize_t *end)
/* Set the start and end arrays up */
for(i=0; i<rank; i++) {
- start[i]=UINT_MAX;
+ start[i]=HSIZET_MAX;
end[i]=0;
} /* end for */