summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2002-06-19 12:54:53 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2002-06-19 12:54:53 (GMT)
commitaefc39ac325f25d1978ad07785ee0b57617d17a5 (patch)
treefca00816adc4c767109b92e4892f77abc40be3b9
parent64b7be4a52b14dfefc7729aaf8be6649fb668cc4 (diff)
downloadhdf5-aefc39ac325f25d1978ad07785ee0b57617d17a5.zip
hdf5-aefc39ac325f25d1978ad07785ee0b57617d17a5.tar.gz
hdf5-aefc39ac325f25d1978ad07785ee0b57617d17a5.tar.bz2
[svn-r5667] Purpose:
Code cleanup Description: Turn on more warnings in the IRIX builds and clean them up. Platforms tested: IRIX64 6.5 (modi4) w/parallel
-rw-r--r--config/irix6.x10
-rw-r--r--hl/tools/gif2h5/decompress.c13
-rw-r--r--hl/tools/gif2h5/gifread.c3
-rw-r--r--perform/pio_engine.c26
-rw-r--r--perform/pio_perf.c8
-rw-r--r--perform/pio_perf.h4
-rw-r--r--src/H5FDmpio.c2
-rw-r--r--src/H5Farray.c6
-rw-r--r--src/H5Fpkg.h6
-rw-r--r--src/H5Fprivate.h6
-rw-r--r--src/H5Zdeflate.c6
-rw-r--r--test/links.c1
-rw-r--r--testpar/t_dset.c28
-rw-r--r--testpar/t_mdset.c8
-rw-r--r--testpar/t_mpi.c5
-rw-r--r--testpar/testphdf5.h14
-rw-r--r--tools/gifconv/decompress.c13
-rw-r--r--tools/gifconv/gifread.c3
18 files changed, 80 insertions, 82 deletions
diff --git a/config/irix6.x b/config/irix6.x
index 97820da..65af4e9 100644
--- a/config/irix6.x
+++ b/config/irix6.x
@@ -53,13 +53,14 @@ case "X-$CC_BASENAME" in
# 1429: the `long long' type is not standard
# 1685: turn off warnings about turning off invalid warnings
# 3201: remark - parameter not referenced
- CFLAGS="$CFLAGS -woff 1174,1429,1209,1196,1685,3201"
+# CFLAGS="$CFLAGS -woff 1174,1429,1209,1196,1685,3201"
+ CFLAGS="$CFLAGS -woff 1209,3201"
# Always turn off these compiler warnings for the old compiler:
# 799: the `long long' type is not standard
# 803: turn off warnings about turning off invalid warnings
# 835: __vfork() (this is an SGI config problem)
- CFLAGS="$CFLAGS -woff 799,803,835"
+# CFLAGS="$CFLAGS -woff 799,803,835"
# Always turn off these loader warnings:
# (notice the peculiar syntax)
@@ -68,10 +69,13 @@ case "X-$CC_BASENAME" in
# 85: duplicate definition preemption (from -lnsl)
# 134: duplicate weak definition preemption (from -lnsl)
CFLAGS="$CFLAGS -Wl,-woff,47,-woff,84,-woff,85,-woff,134"
+
+ # Always turn on full warnings
+ CFLAGS="$CFLAGS -fullwarn"
fi
# Extra debugging flags
- DEBUG_CFLAGS="-g -fullwarn"
+ DEBUG_CFLAGS="-g"
DEBUG_CPPFLAGS=
# Extra production flags
diff --git a/hl/tools/gif2h5/decompress.c b/hl/tools/gif2h5/decompress.c
index 6cc5468..269635d 100644
--- a/hl/tools/gif2h5/decompress.c
+++ b/hl/tools/gif2h5/decompress.c
@@ -19,15 +19,16 @@ char *cmd;
FILE *fp;
+static WORD
+ XC = 0, YC = 0, /* Output X and Y coords of current pixel */
+ InitCodeSize, /* Starting code size, used during Clear */
+ CodeSize, /* Code size, read from GIF header */
+ BytesPerScanline, /* Bytes per scanline in output raster */
+ IWidth, IHeight; /* image dimensions */
static int
BitOffset = 0, /* Bit Offset of next code */
- XC = 0, YC = 0, /* Output X and Y coords of current pixel */
Pass = 0, /* Used by output routine if WORDerlaced pic */
OutCount = 0, /* Decompressor output 'stack count' */
- IWidth, IHeight, /* image dimensions */
- BytesPerScanline, /* Bytes per scanline in output raster */
- CodeSize, /* Code size, read from GIF header */
- InitCodeSize, /* Starting code size, used during Clear */
Code, /* Value returned by ReadCode */
MaxCode, /* limiting value for current code size */
ClearCode, /* GIF clear code */
@@ -162,7 +163,7 @@ Decompress(GIFIMAGEDESC *GifImageDesc, GIFHEAD *GifHead)
OutCount = 0;
BitOffset = 0;
- DataMask = (1L << ((GifHead->PackedField & 0x07) +1)) -1;
+ DataMask = (1 << ((GifHead->PackedField & 0x07) +1)) -1;
Raster = GifImageDesc->GIFImage;
/* Check for image seperator */
diff --git a/hl/tools/gif2h5/gifread.c b/hl/tools/gif2h5/gifread.c
index 3e01801..36cdd13 100644
--- a/hl/tools/gif2h5/gifread.c
+++ b/hl/tools/gif2h5/gifread.c
@@ -382,9 +382,6 @@ ReadDataSubBlocks(BYTE **MemGif2, /* GIF image file input FILE stream
}
-#ifdef COMMENTED_OUT
- *ptr1++ = (BYTE) NULL; /* Add NULL to simulate Terminator value */
-#endif /* COMMENTED_OUT */
*ptr1++ = '\0';
return(ptr2); /* Return a pointer to the sub-block data */
diff --git a/perform/pio_engine.c b/perform/pio_engine.c
index cbd77e7..dfcb465 100644
--- a/perform/pio_engine.c
+++ b/perform/pio_engine.c
@@ -147,7 +147,7 @@ do_pio(parameters param)
char fname[FILENAME_MAX];
int maxprocs;
- int nfiles, nf;
+ long nfiles, nf;
long ndsets;
off_t nelmts;
char *buffer = NULL; /*data buffer pointer */
@@ -190,7 +190,7 @@ do_pio(parameters param)
if (nfiles < 0 ) {
fprintf(stderr,
- "number of files must be >= 0 (%d)\n",
+ "number of files must be >= 0 (%ld)\n",
nfiles);
GOTOERROR(FAIL);
}
@@ -253,7 +253,7 @@ do_pio(parameters param)
MPI_Barrier(pio_comm_g);
- sprintf(base_name, "#pio_tmp_%u", nf);
+ sprintf(base_name, "#pio_tmp_%lu", nf);
pio_create_filename(iot, base_name, fname, sizeof(fname));
set_time(res.timers, HDF5_GROSS_WRITE_FIXED_DIMS, START);
@@ -488,7 +488,7 @@ do_write(results *res, file_descr *fd, parameters *parms, long ndsets,
#endif
/* calculate dataset parameters. data type is always native C int */
- dset_size = nelmts * ELMT_SIZE;
+ dset_size = nelmts * (off_t)ELMT_SIZE;
nelmts_in_buf = buf_size/ELMT_SIZE;
/* hdf5 data space setup */
@@ -692,7 +692,7 @@ do_write(results *res, file_descr *fd, parameters *parms, long ndsets,
/* Contiguous pattern */
/* need to (off_t) the elmnts_begin expression because they */
/* may be of smaller sized integer types */
- file_offset = dset_offset + (off_t)(elmts_begin + nelmts_xfer)*ELMT_SIZE;
+ file_offset = dset_offset + (off_t)(elmts_begin + nelmts_xfer)*(off_t)ELMT_SIZE;
/* only care if seek returns error */
rc = POSIXSEEK(fd->posixfd, file_offset) < 0 ? -1 : 0;
@@ -707,7 +707,7 @@ do_write(results *res, file_descr *fd, parameters *parms, long ndsets,
size_t xferred=0;
size_t toxfer=0;
- file_offset = dset_offset + (off_t)(elmts_begin + nelmts_xfer)*ELMT_SIZE;
+ file_offset = dset_offset + (off_t)(elmts_begin + nelmts_xfer)*(off_t)ELMT_SIZE;
if (pio_debug_level >= 4) {
HDprint_rank(output);
HDfprintf(output,
@@ -723,7 +723,7 @@ HDfprintf(output,
toxfer = nelmts_toxfer - xferred;
/* Skip offset over blocks of other processes */
file_offset = dset_offset +
- (off_t)(elmts_begin + (nelmts_xfer+xferred)*pio_mpi_nprocs_g)*ELMT_SIZE;
+ (off_t)(elmts_begin + (nelmts_xfer+xferred)*pio_mpi_nprocs_g)*(off_t)ELMT_SIZE;
if (pio_debug_level >= 4) {
HDprint_rank(output);
HDfprintf(output,
@@ -749,7 +749,7 @@ HDfprintf(output,
break;
case MPIO:
- mpi_offset = dset_offset + (elmts_begin + nelmts_xfer)*ELMT_SIZE;
+ mpi_offset = dset_offset + (elmts_begin + nelmts_xfer)*(off_t)ELMT_SIZE;
mrc = MPI_File_write_at(fd->mpifd, mpi_offset, buffer,
(int)(nelmts_toxfer), ELMT_MPI_TYPE,
&mpi_status);
@@ -872,7 +872,7 @@ do_read(results *res, file_descr *fd, parameters *parms, long ndsets,
#endif
/* calculate dataset parameters. data type is always native C int */
- dset_size = nelmts * ELMT_SIZE;
+ dset_size = nelmts * (off_t)ELMT_SIZE;
nelmts_in_buf = buf_size/ELMT_SIZE;
/* hdf5 data space setup */
@@ -1029,7 +1029,7 @@ do_read(results *res, file_descr *fd, parameters *parms, long ndsets,
/* Contiguous pattern */
/* need to (off_t) the elmnts_begin expression because they */
/* may be of smaller sized integer types */
- file_offset = dset_offset + (off_t)(elmts_begin + nelmts_xfer)*ELMT_SIZE;
+ file_offset = dset_offset + (off_t)(elmts_begin + nelmts_xfer)*(off_t)ELMT_SIZE;
/* only care if seek returns error */
rc = POSIXSEEK(fd->posixfd, file_offset) < 0 ? -1 : 0;
@@ -1044,7 +1044,7 @@ do_read(results *res, file_descr *fd, parameters *parms, long ndsets,
size_t xferred=0;
size_t toxfer=0;
- file_offset = dset_offset + (off_t)(elmts_begin + nelmts_xfer)*ELMT_SIZE;
+ file_offset = dset_offset + (off_t)(elmts_begin + nelmts_xfer)*(off_t)ELMT_SIZE;
if (pio_debug_level >= 4) {
HDprint_rank(output);
HDfprintf(output,
@@ -1060,7 +1060,7 @@ HDfprintf(output,
toxfer = nelmts_toxfer - xferred;
/* Skip offset over blocks of other processes */
file_offset = dset_offset +
- (off_t)(elmts_begin + (nelmts_xfer+xferred)*pio_mpi_nprocs_g)*ELMT_SIZE;
+ (off_t)(elmts_begin + (nelmts_xfer+xferred)*pio_mpi_nprocs_g)*(off_t)ELMT_SIZE;
if (pio_debug_level >= 4) {
HDprint_rank(output);
HDfprintf(output,
@@ -1086,7 +1086,7 @@ HDfprintf(output,
break;
case MPIO:
- mpi_offset = dset_offset + (elmts_begin + nelmts_xfer)*ELMT_SIZE;
+ mpi_offset = dset_offset + (elmts_begin + nelmts_xfer)*(off_t)ELMT_SIZE;
mrc = MPI_File_read_at(fd->mpifd, mpi_offset, buffer,
(int)(nelmts_toxfer), ELMT_MPI_TYPE,
diff --git a/perform/pio_perf.c b/perform/pio_perf.c
index f27cec9..f0b158c 100644
--- a/perform/pio_perf.c
+++ b/perform/pio_perf.c
@@ -246,7 +246,7 @@ struct options {
off_t file_size; /* size of file */
long num_dsets; /* number of datasets */
long num_files; /* number of files */
- long num_iters; /* number of iterations */
+ int num_iters; /* number of iterations */
int max_num_procs; /* maximum number of processes to use */
int min_num_procs; /* minimum number of processes to use */
size_t max_xfer_size; /* maximum transfer buffer size */
@@ -698,7 +698,7 @@ run_test(iotype iot, parameters parms, struct options *opts)
static void
output_all_info(minmax *mm, int count, int indent_level)
{
- register int i;
+ int i;
for (i = 0; i < count; ++i) {
print_indent(indent_level);
@@ -743,7 +743,7 @@ get_minmax(minmax *mm, double val)
static minmax
accumulate_minmax_stuff(minmax *mm, int count)
{
- register int i;
+ int i;
minmax total_mm;
total_mm.sum = 0.0;
@@ -864,7 +864,7 @@ output_results(const struct options *opts, const char *name, minmax *table,
total_mm = accumulate_minmax_stuff(table, table_size);
print_indent(3);
- output_report("%s (%d iteration(s)):\n", name,(int)table_size);
+ output_report("%s (%d iteration(s)):\n", name,table_size);
/* Note: The maximum throughput uses the minimum amount of time & vice versa */
diff --git a/perform/pio_perf.h b/perform/pio_perf.h
index e812f16..b9284df 100644
--- a/perform/pio_perf.h
+++ b/perform/pio_perf.h
@@ -26,10 +26,10 @@ typedef enum iotype_ {
typedef struct parameters_ {
iotype io_type; /* The type of IO test to perform */
int num_procs; /* Maximum number of processes to use */
- int num_files; /* Number of files to create */
+ long num_files; /* Number of files to create */
long num_dsets; /* Number of datasets to create */
off_t num_elmts; /* Number of native ints in each dset */
- int num_iters; /* Number of times to loop doing the IO */
+ int num_iters; /* Number of times to loop doing the IO */
size_t buf_size; /* Buffer size */
size_t block_size; /* interleaved block size */
hsize_t h5_align; /* HDF5 object alignment */
diff --git a/src/H5FDmpio.c b/src/H5FDmpio.c
index 3e9d200..064341b 100644
--- a/src/H5FDmpio.c
+++ b/src/H5FDmpio.c
@@ -989,7 +989,9 @@ H5FD_mpio_close(H5FD_t *_file)
static herr_t
H5FD_mpio_query(const H5FD_t *_file, unsigned long *flags /* out */)
{
+#ifndef NDEBUG
const H5FD_mpio_t *file = (const H5FD_mpio_t*)_file;
+#endif /* NDEBUG */
herr_t ret_value=SUCCEED;
FUNC_ENTER_NOAPI(H5FD_mpio_query, FAIL);
diff --git a/src/H5Farray.c b/src/H5Farray.c
index 859f7ae..7d046cd 100644
--- a/src/H5Farray.c
+++ b/src/H5Farray.c
@@ -265,8 +265,7 @@ H5F_arr_read(H5F_t *f, hid_t dxpl_id, const H5O_layout_t *layout,
*/
unsigned long max, min, temp;
- temp = nelmts;
- assert(temp==nelmts); /* verify no overflow */
+ H5_ASSIGN_OVERFLOW(temp,nelmts,hsize_t,unsigned long);
MPI_Allreduce(&temp, &max, 1, MPI_UNSIGNED_LONG, MPI_MAX,
H5FD_mpio_communicator(f->shared->lf));
MPI_Allreduce(&temp, &min, 1, MPI_UNSIGNED_LONG, MPI_MIN,
@@ -516,8 +515,7 @@ H5F_arr_write(H5F_t *f, hid_t dxpl_id, const H5O_layout_t *layout,
*/
unsigned long max, min, temp;
- temp = nelmts;
- assert(temp==nelmts); /* verify no overflow */
+ H5_ASSIGN_OVERFLOW(temp,nelmts,hsize_t,unsigned long);
MPI_Allreduce(&temp, &max, 1, MPI_UNSIGNED_LONG, MPI_MAX,
H5FD_mpio_communicator(f->shared->lf));
MPI_Allreduce(&temp, &min, 1, MPI_UNSIGNED_LONG, MPI_MIN,
diff --git a/src/H5Fpkg.h b/src/H5Fpkg.h
index 6f034b6..10ed39b 100644
--- a/src/H5Fpkg.h
+++ b/src/H5Fpkg.h
@@ -196,12 +196,6 @@ __DLL__ herr_t H5F_istore_write(H5F_t *f, hid_t dxpl_id,
const hsize_t size_m[], const hssize_t offset_m[],
const hssize_t offset[], const hsize_t size[],
const void *buf);
-#ifdef H5_HAVE_PARALLEL
-__DLL__ herr_t H5F_istore_allocate (H5F_t *f, hid_t dxpl_id,
- const struct H5O_layout_t *layout,
- const hsize_t *space_dim,
- struct H5P_genplist_t *dc_plist);
-#endif /* H5_HAVE_PARALLEL */
/* Functions that operate on contiguous storage wrt boot block */
__DLL__ herr_t H5F_contig_read(H5F_t *f, hsize_t max_data, H5FD_mem_t type, haddr_t addr,
diff --git a/src/H5Fprivate.h b/src/H5Fprivate.h
index 6c7e913..a4a2a3d 100644
--- a/src/H5Fprivate.h
+++ b/src/H5Fprivate.h
@@ -391,6 +391,12 @@ __DLL__ herr_t H5F_seq_writev(H5F_t *f, hid_t dxpl_id,
/* Functions that operate on indexed storage */
+#ifdef H5_HAVE_PARALLEL
+__DLL__ herr_t H5F_istore_allocate (H5F_t *f, hid_t dxpl_id,
+ const struct H5O_layout_t *layout,
+ const hsize_t *space_dim,
+ struct H5P_genplist_t *dc_plist);
+#endif /* H5_HAVE_PARALLEL */
__DLL__ hsize_t H5F_istore_allocated(H5F_t *f, unsigned ndims, haddr_t addr);
__DLL__ herr_t H5F_istore_dump_btree(H5F_t *f, FILE *stream, unsigned ndims,
haddr_t addr);
diff --git a/src/H5Zdeflate.c b/src/H5Zdeflate.c
index 3f43310..43ffbd5 100644
--- a/src/H5Zdeflate.c
+++ b/src/H5Zdeflate.c
@@ -11,7 +11,7 @@
#include "H5Zprivate.h"
#ifdef H5_HAVE_ZLIB_H
-# include <zlib.h>
+# include "zlib.h"
#else
/* Make sure compression is disabled too. */
#undef H5_HAVE_COMPRESS2
@@ -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 = (uInt)nbytes;
+ H5_ASSIGN_OVERFLOW(z_strm.avail_in,nbytes,size_t,uInt);
z_strm.next_out = outbuf;
- z_strm.avail_out = (uInt)nalloc;
+ H5_ASSIGN_OVERFLOW(z_strm.avail_out,nalloc,size_t,uInt);
if (Z_OK!=inflateInit(&z_strm)) {
HGOTO_ERROR(H5E_PLINE, H5E_CANTINIT, 0, "inflateInit() failed");
}
diff --git a/test/links.c b/test/links.c
index 0684c11..53ba3fc 100644
--- a/test/links.c
+++ b/test/links.c
@@ -111,7 +111,6 @@ new_links(hid_t fapl)
hid_t dset1, dset2;
char filename[1024];
static hsize_t size[1] = {1};
- H5G_stat_t sb_soft2;
TESTING("H5Glink2 function");
diff --git a/testpar/t_dset.c b/testpar/t_dset.c
index 3639e7a..91b6bd5 100644
--- a/testpar/t_dset.c
+++ b/testpar/t_dset.c
@@ -97,9 +97,9 @@ if (verbose) printf("slab_set wholeset\n");
}
if (verbose){
printf("start[]=(%ld,%ld), count[]=(%lu,%lu), stride[]=(%lu,%lu), block[]=(%lu,%lu), total datapoints=%lu\n",
- start[0], start[1], count[0], count[1],
- stride[0], stride[1], block[0], block[1],
- block[0]*block[1]*count[0]*count[1]);
+ (long)start[0], (long)start[1], (unsigned long)count[0], (unsigned long)count[1],
+ (unsigned long)stride[0], (unsigned long)stride[1], (unsigned long)block[0], (unsigned long)block[1],
+ (unsigned long)(block[0]*block[1]*count[0]*count[1]));
}
}
@@ -135,13 +135,13 @@ void dataset_print(hssize_t start[], hsize_t count[], hsize_t stride[], hsize_t
/* print the column heading */
printf("%-8s", "Cols:");
for (j=0; j < block[1]; j++){
- printf("%3ld ", start[1]+j);
+ printf("%3ld ", (long)start[1]+j);
}
printf("\n");
/* print the slab data */
for (i=0; i < block[0]; i++){
- printf("Row %2ld: ", i+start[0]);
+ printf("Row %2ld: ", (long)(i+start[0]));
for (j=0; j < block[1]; j++){
printf("%03d ", *dataptr++);
}
@@ -155,17 +155,14 @@ void dataset_print(hssize_t start[], hsize_t count[], hsize_t stride[], hsize_t
*/
int dataset_vrfy(hssize_t start[], hsize_t count[], hsize_t stride[], hsize_t block[], DATATYPE *dataset, DATATYPE *original)
{
- DATATYPE *dataptr = dataset;
- DATATYPE *originptr = original;
-
int i, j, vrfyerrs;
/* print it if verbose */
if (verbose) {
printf("dataset_vrfy dumping:::\n");
printf("start(%ld, %ld), count(%lu, %lu), stride(%lu, %lu), block(%lu, %lu)\n",
- start[0], start[1], count[0], count[1],
- stride[0], stride[1], block[0], block[1]);
+ (long)start[0], (long)start[1], (unsigned long)count[0], (unsigned long)count[1],
+ (unsigned long)stride[0], (unsigned long)stride[1], (unsigned long)block[0], (unsigned long)block[1]);
printf("original values:\n");
dataset_print(start, count, stride, block, original);
printf("compared values:\n");
@@ -224,9 +221,7 @@ dataset_writeInd(char *filename)
hsize_t block[RANK]; /* for hyperslab setting */
herr_t ret; /* Generic return value */
- int i, j;
int mpi_size, mpi_rank;
- char *fname;
MPI_Comm comm = MPI_COMM_WORLD;
MPI_Info info = MPI_INFO_NULL;
@@ -356,7 +351,6 @@ dataset_readInd(char *filename)
{
hid_t fid; /* HDF5 file ID */
hid_t acc_tpl; /* File access templates */
- hid_t sid; /* Dataspace ID */
hid_t file_dataspace; /* File dataspace ID */
hid_t mem_dataspace; /* memory dataspace ID */
hid_t dataset1, dataset2; /* Dataset ID */
@@ -368,7 +362,6 @@ dataset_readInd(char *filename)
hsize_t block[RANK]; /* for hyperslab setting */
herr_t ret; /* Generic return value */
- int i, j;
int mpi_size, mpi_rank;
MPI_Comm comm = MPI_COMM_WORLD;
@@ -702,7 +695,6 @@ dataset_readAll(char *filename)
hid_t fid; /* HDF5 file ID */
hid_t acc_tpl; /* File access templates */
hid_t xfer_plist; /* Dataset transfer properties list */
- hid_t sid; /* Dataspace ID */
hid_t file_dataspace; /* File dataspace ID */
hid_t mem_dataspace; /* memory dataspace ID */
hid_t dataset1, dataset2; /* Dataset ID */
@@ -939,9 +931,7 @@ extend_writeInd(char *filename)
hsize_t block[RANK]; /* for hyperslab setting */
herr_t ret; /* Generic return value */
- int i, j;
int mpi_size, mpi_rank;
- char *fname;
MPI_Comm comm = MPI_COMM_WORLD;
MPI_Info info = MPI_INFO_NULL;
@@ -983,7 +973,7 @@ extend_writeInd(char *filename)
/* set up dataset storage chunk sizes and creation property list */
if (verbose)
- printf("chunks[]=%lu,%lu\n", chunk_dims[0], chunk_dims[1]);
+ printf("chunks[]=%lu,%lu\n", (unsigned long)chunk_dims[0], (unsigned long)chunk_dims[1]);
dataset_pl = H5Pcreate(H5P_DATASET_CREATE);
VRFY((dataset_pl >= 0), "H5Pcreate succeeded");
ret = H5Pset_chunk(dataset_pl, RANK, chunk_dims);
@@ -1130,7 +1120,6 @@ extend_readInd(char *filename)
{
hid_t fid; /* HDF5 file ID */
hid_t acc_tpl; /* File access templates */
- hid_t sid; /* Dataspace ID */
hid_t file_dataspace; /* File dataspace ID */
hid_t mem_dataspace; /* memory dataspace ID */
hid_t dataset1, dataset2; /* Dataset ID */
@@ -1144,7 +1133,6 @@ extend_readInd(char *filename)
hsize_t block[RANK]; /* for hyperslab setting */
herr_t ret; /* Generic return value */
- int i, j;
int mpi_size, mpi_rank;
MPI_Comm comm = MPI_COMM_WORLD;
diff --git a/testpar/t_mdset.c b/testpar/t_mdset.c
index 271aed0..bd06cc9 100644
--- a/testpar/t_mdset.c
+++ b/testpar/t_mdset.c
@@ -109,7 +109,7 @@ void multiple_dset_write(char *filename, int ndatasets)
void multiple_group_write(char *filename, int ngroups)
{
int mpi_rank, mpi_size;
- int i, j, l, m;
+ int m;
char gname[64];
hid_t fid, gid, plist, memspace, filespace;
hssize_t chunk_origin[DIM];
@@ -248,7 +248,7 @@ void create_group_recursive(hid_t memspace, hid_t filespace, hid_t gid,
void multiple_group_read(char *filename, int ngroups)
{
int mpi_rank, mpi_size, error_num;
- int l, m;
+ int m;
char gname[64];
hid_t plist, fid, gid, memspace, filespace;
hssize_t chunk_origin[DIM];
@@ -316,7 +316,6 @@ int read_dataset(hid_t memspace, hid_t filespace, hid_t gid)
char dname[32];
DATATYPE *outdata, *indata;
hid_t did;
- hsize_t block[DIM]={SIZE,SIZE};
MPI_Comm_rank(MPI_COMM_WORLD, &mpi_rank);
MPI_Comm_size(MPI_COMM_WORLD, &mpi_size);
@@ -350,6 +349,9 @@ int read_dataset(hid_t memspace, hid_t filespace, hid_t gid)
H5Dclose(did);
}
+ free(indata);
+ free(outdata);
+
return vrfy_errors;
}
diff --git a/testpar/t_mpi.c b/testpar/t_mpi.c
index 3758d75..8f6b55a 100644
--- a/testpar/t_mpi.c
+++ b/testpar/t_mpi.c
@@ -25,7 +25,6 @@ hid_t fapl; /* file access property list */
/* protocols */
static void test_mpio_overlap_writes(char *filename);
-static void test_mpio_offset(void);
static void test_mpio_gb_file(char *filename);
static void test_mpio_gb_file(char *filename);
static int parse_options(int argc, char **argv);
@@ -137,7 +136,7 @@ test_mpio_overlap_writes(char *filename)
if ((buf[i] != expected) &&
(vrfyerrs++ < MAX_ERR_REPORT || verbose))
printf("proc %d: found data error at [%ld], expect %d, got %d\n",
- mpi_rank, mpi_off+i, expected, buf[i]);
+ mpi_rank, (long)(mpi_off+i), expected, buf[i]);
}
if (vrfyerrs > MAX_ERR_REPORT && !verbose)
printf("proc %d: [more errors ...]\n", mpi_rank);
@@ -332,7 +331,7 @@ test_mpio_gb_file(char *filename)
if ((*(buf+j) != expected) &&
(vrfyerrs++ < MAX_ERR_REPORT || verbose))
printf("proc %d: found data error at [%ld+%d], expect %d, got %d\n",
- mpi_rank, mpi_off, j, expected, *(buf+j));
+ mpi_rank, (long)mpi_off, j, expected, *(buf+j));
}
if (vrfyerrs > MAX_ERR_REPORT && !verbose)
printf("proc %d: [more errors ...]\n", mpi_rank);
diff --git a/testpar/testphdf5.h b/testpar/testphdf5.h
index fb613bf..636769d 100644
--- a/testpar/testphdf5.h
+++ b/testpar/testphdf5.h
@@ -102,7 +102,17 @@ extern void *old_client_data; /*previous error handler arg.*/
extern int facc_type; /*Test file access type */
/* prototypes */
-hid_t
-create_faccess_plist(MPI_Comm comm, MPI_Info info, int facc_type );
+hid_t create_faccess_plist(MPI_Comm comm, MPI_Info info, int facc_type );
+void multiple_dset_write(char *filename, int ndatasets);
+void multiple_group_write(char *filename, int ngroups);
+void multiple_group_read(char *filename, int ngroups);
+void test_split_comm_access(char *filename);
+void dataset_writeInd(char *filename);
+void dataset_writeAll(char *filename);
+void extend_writeInd(char *filename);
+void dataset_readInd(char *filename);
+void dataset_readAll(char *filename);
+void extend_readInd(char *filename);
+int dataset_vrfy(hssize_t start[], hsize_t count[], hsize_t stride[], hsize_t block[], DATATYPE *dataset, DATATYPE *original);
#endif /* PHDF5TEST_H */
diff --git a/tools/gifconv/decompress.c b/tools/gifconv/decompress.c
index 6cc5468..269635d 100644
--- a/tools/gifconv/decompress.c
+++ b/tools/gifconv/decompress.c
@@ -19,15 +19,16 @@ char *cmd;
FILE *fp;
+static WORD
+ XC = 0, YC = 0, /* Output X and Y coords of current pixel */
+ InitCodeSize, /* Starting code size, used during Clear */
+ CodeSize, /* Code size, read from GIF header */
+ BytesPerScanline, /* Bytes per scanline in output raster */
+ IWidth, IHeight; /* image dimensions */
static int
BitOffset = 0, /* Bit Offset of next code */
- XC = 0, YC = 0, /* Output X and Y coords of current pixel */
Pass = 0, /* Used by output routine if WORDerlaced pic */
OutCount = 0, /* Decompressor output 'stack count' */
- IWidth, IHeight, /* image dimensions */
- BytesPerScanline, /* Bytes per scanline in output raster */
- CodeSize, /* Code size, read from GIF header */
- InitCodeSize, /* Starting code size, used during Clear */
Code, /* Value returned by ReadCode */
MaxCode, /* limiting value for current code size */
ClearCode, /* GIF clear code */
@@ -162,7 +163,7 @@ Decompress(GIFIMAGEDESC *GifImageDesc, GIFHEAD *GifHead)
OutCount = 0;
BitOffset = 0;
- DataMask = (1L << ((GifHead->PackedField & 0x07) +1)) -1;
+ DataMask = (1 << ((GifHead->PackedField & 0x07) +1)) -1;
Raster = GifImageDesc->GIFImage;
/* Check for image seperator */
diff --git a/tools/gifconv/gifread.c b/tools/gifconv/gifread.c
index 3e01801..36cdd13 100644
--- a/tools/gifconv/gifread.c
+++ b/tools/gifconv/gifread.c
@@ -382,9 +382,6 @@ ReadDataSubBlocks(BYTE **MemGif2, /* GIF image file input FILE stream
}
-#ifdef COMMENTED_OUT
- *ptr1++ = (BYTE) NULL; /* Add NULL to simulate Terminator value */
-#endif /* COMMENTED_OUT */
*ptr1++ = '\0';
return(ptr2); /* Return a pointer to the sub-block data */