diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2001-07-12 16:29:30 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2001-07-12 16:29:30 (GMT) |
commit | 5172c6aa70677f3252fb407069af35f5dc09a6d6 (patch) | |
tree | 993302adb989fe64b53abaf96ce1eb198eae7e6e /src | |
parent | 7c706d9d1447319ef86f4725344f02dae3db7bb9 (diff) | |
download | hdf5-5172c6aa70677f3252fb407069af35f5dc09a6d6.zip hdf5-5172c6aa70677f3252fb407069af35f5dc09a6d6.tar.gz hdf5-5172c6aa70677f3252fb407069af35f5dc09a6d6.tar.bz2 |
[svn-r4196] Purpose:
Bug Fix
Description:
Using a 'long long' type (i.e. hsize_t) in a switch statement is apparently
not allowed by the HP/UX 10.20 system compiler and causes the compile to
fail.
Solution:
Cast the variable to a size_t for the switch.
Platforms tested:
HP/UX 10.20 (sangamon)
Diffstat (limited to 'src')
-rw-r--r-- | src/H5Shyper.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/H5Shyper.c b/src/H5Shyper.c index 2257263..6b59f24 100644 --- a/src/H5Shyper.c +++ b/src/H5Shyper.c @@ -2834,7 +2834,11 @@ for(i=0; i<ndims; i++) } /* end while */ #else /* NO_DUFFS_DEVICE */ duffs_index = (fast_dim_count + 7) / 8; - switch (fast_dim_count % 8) { + /* The following size_t cast is required on HPUX 10.20 in + * order to make the system compuiler happy. It can be + * removed when we are no longer supporting that platform. -QAK + */ + switch (((size_t)fast_dim_count) % 8) { case 0: do { @@ -3503,7 +3507,11 @@ for(i=0; i<ndims; i++) } /* end while */ #else /* NO_DUFFS_DEVICE */ duffs_index = (fast_dim_count + 7) / 8; - switch (fast_dim_count % 8) { + /* The following size_t cast is required on HPUX 10.20 in + * order to make the system compuiler happy. It can be + * removed when we are no longer supporting that platform. -QAK + */ + switch (((size_t)fast_dim_count) % 8) { case 0: do { |