From 7c8d70200303e03fea24a61707658392eb450911 Mon Sep 17 00:00:00 2001 From: Quincey Koziol Date: Tue, 19 Jun 2001 12:35:45 -0500 Subject: [svn-r4018] Purpose: Code cleanup Description: Removed some more warnings during compilation on SGI machines.. Platforms tested: Irix64-6.5 (modi4) --- src/H5Dseq.c | 12 ------------ src/H5Fseq.c | 12 ------------ src/H5Odtype.c | 2 +- src/H5Zdeflate.c | 6 +++--- 4 files changed, 4 insertions(+), 28 deletions(-) diff --git a/src/H5Dseq.c b/src/H5Dseq.c index c6e29a1..3868202 100644 --- a/src/H5Dseq.c +++ b/src/H5Dseq.c @@ -179,8 +179,6 @@ H5F_seq_read(H5F_t *f, hid_t dxpl_id, const struct H5O_layout_t *layout, case H5D_CHUNKED: { - uintn leading_partials; /* Flag set if there are leading partial hyperslabs to take care of */ - /* * This method is unable to access external raw data files */ @@ -227,12 +225,9 @@ printf("%s: acc=%ld, down_size[%d]=%ld\n",FUNC,(long)acc,i,(long)down_size[i]); } /* end for */ /* Compute the hyperslab offset from the address given */ - leading_partials=0; for(i=ndims-1; i>=0; i--) { coords[i]=addr%dset_dims[i]; addr/=dset_dims[i]; - if(i>0 && coords[i]>0) - leading_partials=1; #ifdef QAK printf("%s: addr=%lu, coords[%d]=%ld\n",FUNC,(unsigned long)addr,i,(long)coords[i]); #endif /* QAK */ @@ -240,7 +235,6 @@ printf("%s: addr=%lu, coords[%d]=%ld\n",FUNC,(unsigned long)addr,i,(long)coords[ coords[ndims]=0; /* No offset for element info */ #ifdef QAK printf("%s: addr=%lu, coords[%d]=%ld\n",FUNC,(unsigned long)addr,ndims,(long)coords[ndims]); -printf("%s: leading_partials=%u\n",FUNC,leading_partials); #endif /* QAK */ /* @@ -622,8 +616,6 @@ H5F_seq_write(H5F_t *f, hid_t dxpl_id, const struct H5O_layout_t *layout, case H5D_CHUNKED: { - uintn leading_partials; /* Flag set if there are leading partial hyperslabs to take care of */ - /* * This method is unable to access external raw data files */ @@ -670,12 +662,9 @@ printf("%s: acc=%ld, down_size[%d]=%ld\n",FUNC,(long)acc,i,(long)down_size[i]); } /* end for */ /* Compute the hyperslab offset from the address given */ - leading_partials=0; for(i=ndims-1; i>=0; i--) { coords[i]=addr%dset_dims[i]; addr/=dset_dims[i]; - if(i>0 && coords[i]>0) - leading_partials=1; #ifdef QAK printf("%s: addr=%lu, dset_dims[%d]=%ld, coords[%d]=%ld\n",FUNC,(unsigned long)addr,i,(long)dset_dims[i],i,(long)coords[i]); #endif /* QAK */ @@ -683,7 +672,6 @@ printf("%s: addr=%lu, dset_dims[%d]=%ld, coords[%d]=%ld\n",FUNC,(unsigned long)a coords[ndims]=0; /* No offset for element info */ #ifdef QAK printf("%s: addr=%lu, coords[%d]=%ld\n",FUNC,(unsigned long)addr,ndims,(long)coords[ndims]); -printf("%s: leading_partials=%u\n",FUNC,leading_partials); #endif /* QAK */ /* diff --git a/src/H5Fseq.c b/src/H5Fseq.c index c6e29a1..3868202 100644 --- a/src/H5Fseq.c +++ b/src/H5Fseq.c @@ -179,8 +179,6 @@ H5F_seq_read(H5F_t *f, hid_t dxpl_id, const struct H5O_layout_t *layout, case H5D_CHUNKED: { - uintn leading_partials; /* Flag set if there are leading partial hyperslabs to take care of */ - /* * This method is unable to access external raw data files */ @@ -227,12 +225,9 @@ printf("%s: acc=%ld, down_size[%d]=%ld\n",FUNC,(long)acc,i,(long)down_size[i]); } /* end for */ /* Compute the hyperslab offset from the address given */ - leading_partials=0; for(i=ndims-1; i>=0; i--) { coords[i]=addr%dset_dims[i]; addr/=dset_dims[i]; - if(i>0 && coords[i]>0) - leading_partials=1; #ifdef QAK printf("%s: addr=%lu, coords[%d]=%ld\n",FUNC,(unsigned long)addr,i,(long)coords[i]); #endif /* QAK */ @@ -240,7 +235,6 @@ printf("%s: addr=%lu, coords[%d]=%ld\n",FUNC,(unsigned long)addr,i,(long)coords[ coords[ndims]=0; /* No offset for element info */ #ifdef QAK printf("%s: addr=%lu, coords[%d]=%ld\n",FUNC,(unsigned long)addr,ndims,(long)coords[ndims]); -printf("%s: leading_partials=%u\n",FUNC,leading_partials); #endif /* QAK */ /* @@ -622,8 +616,6 @@ H5F_seq_write(H5F_t *f, hid_t dxpl_id, const struct H5O_layout_t *layout, case H5D_CHUNKED: { - uintn leading_partials; /* Flag set if there are leading partial hyperslabs to take care of */ - /* * This method is unable to access external raw data files */ @@ -670,12 +662,9 @@ printf("%s: acc=%ld, down_size[%d]=%ld\n",FUNC,(long)acc,i,(long)down_size[i]); } /* end for */ /* Compute the hyperslab offset from the address given */ - leading_partials=0; for(i=ndims-1; i>=0; i--) { coords[i]=addr%dset_dims[i]; addr/=dset_dims[i]; - if(i>0 && coords[i]>0) - leading_partials=1; #ifdef QAK printf("%s: addr=%lu, dset_dims[%d]=%ld, coords[%d]=%ld\n",FUNC,(unsigned long)addr,i,(long)dset_dims[i],i,(long)coords[i]); #endif /* QAK */ @@ -683,7 +672,6 @@ printf("%s: addr=%lu, dset_dims[%d]=%ld, coords[%d]=%ld\n",FUNC,(unsigned long)a coords[ndims]=0; /* No offset for element info */ #ifdef QAK printf("%s: addr=%lu, coords[%d]=%ld\n",FUNC,(unsigned long)addr,ndims,(long)coords[ndims]); -printf("%s: leading_partials=%u\n",FUNC,leading_partials); #endif /* QAK */ /* diff --git a/src/H5Odtype.c b/src/H5Odtype.c index 58b68a2..8e43762 100644 --- a/src/H5Odtype.c +++ b/src/H5Odtype.c @@ -1288,7 +1288,7 @@ H5O_dtype_debug(H5F_t *f, const void *mesg, FILE *stream, dt->u.array.ndims); fprintf(stream, "%*s%-*s {", indent, "", fwidth, "Dim Size:"); for (i=0; iu.array.ndims; i++) { - fprintf (stream, "%s%u", i?", ":"", dt->u.array.dim[i]); + fprintf (stream, "%s%u", i?", ":"", (unsigned)dt->u.array.dim[i]); } fprintf (stream, "}\n"); fprintf(stream, "%*s%-*s {", indent, "", fwidth, "Dim Permutation:"); diff --git a/src/H5Zdeflate.c b/src/H5Zdeflate.c index 66d29a8..753cc9e 100644 --- a/src/H5Zdeflate.c +++ b/src/H5Zdeflate.c @@ -78,9 +78,9 @@ H5Z_filter_deflate (unsigned UNUSED flags, size_t cd_nelmts, } HDmemset(&z_strm, 0, sizeof(z_strm)); z_strm.next_in = *buf; - z_strm.avail_in = nbytes; + z_strm.avail_in = (uInt)nbytes; z_strm.next_out = outbuf; - z_strm.avail_out = nalloc; + z_strm.avail_out = (uInt)nalloc; if (Z_OK!=inflateInit(&z_strm)) { HGOTO_ERROR(H5E_PLINE, H5E_CANTINIT, 0, "inflateInit() failed"); } @@ -100,7 +100,7 @@ H5Z_filter_deflate (unsigned UNUSED flags, size_t cd_nelmts, "uncompression"); } z_strm.next_out = (unsigned char*)outbuf + z_strm.total_out; - z_strm.avail_out = nalloc - z_strm.total_out; + z_strm.avail_out = (uInt)(nalloc - z_strm.total_out); } } -- cgit v0.12