diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2016-07-22 22:43:18 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2016-07-22 22:43:18 (GMT) |
commit | 4af66b09e03af4e9b0b6a1293dfe746f48106aba (patch) | |
tree | 0cb162e0921a0a774a433f9d3cd9f08c44bbe57d /tools/h5import | |
parent | 9b597a48552f5201b37793a4c6fece4fd9f1c346 (diff) | |
download | hdf5-4af66b09e03af4e9b0b6a1293dfe746f48106aba.zip hdf5-4af66b09e03af4e9b0b6a1293dfe746f48106aba.tar.gz hdf5-4af66b09e03af4e9b0b6a1293dfe746f48106aba.tar.bz2 |
[svn-r30219] Description:
More warning cleaups: down to 770 warnings (from ~940) in 134 files (from
148), with 28 unique kinds of warnings (from 31).
Tested on:
MacOSX/64 10.11.5 (amazon) w/serial & parallel
(h5committest forthcoming)
Diffstat (limited to 'tools/h5import')
-rw-r--r-- | tools/h5import/h5import.c | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/tools/h5import/h5import.c b/tools/h5import/h5import.c index 9617df3..d1aab0c 100644 --- a/tools/h5import/h5import.c +++ b/tools/h5import/h5import.c @@ -1439,7 +1439,7 @@ static int processConfigurationFile(char *infile, struct Input *in) #endif if (HDstrcmp("H5T_VARIABLE;", temp)) { char *more = temp; - ival = HDstrtol(more, &more, 10); + ival = (int)HDstrtol(more, &more, 10); if (getInputSize(in, ival) == -1) { (void) HDfprintf(stderr, err5b, infile); goto error; @@ -2279,13 +2279,13 @@ static int parseDimensions(struct Input *in, char *strm) HDstrncpy(temp, strm, sizeof(temp)); temp[sizeof(temp) - 1] = '\0'; in->sizeOfDimension[i++] - = HDstrtol(HDstrtok (temp, delimiter), NULL, BASE_10); + = HDstrtoull(HDstrtok (temp, delimiter), NULL, BASE_10); while (1) { token = HDstrtok (NULL, delimiter); if (token == NULL) break; - in->sizeOfDimension[i++] = HDstrtol(token, NULL, BASE_10); + in->sizeOfDimension[i++] = HDstrtoull(token, NULL, BASE_10); } return (0); } @@ -3121,7 +3121,7 @@ static int getRank(struct Input *in, FILE *strm) /* same as getChunkedDimensionSizes. But defined separately for extensibility */ static int getDimensionSizes(struct Input *in, FILE *strm) { - int ival; + unsigned long long ullval; int i = 0; const char *err1 = "Unable to allocate dynamic memory.\n"; @@ -3132,8 +3132,8 @@ static int getDimensionSizes(struct Input *in, FILE *strm) return (-1); } - while (fscanf(strm, "%d", (&ival)) == 1) - in->sizeOfDimension[i++] = ival; + while (fscanf(strm, "%llu", (&ullval)) == 1) + in->sizeOfDimension[i++] = ullval; if (in->rank != i) { (void) HDfprintf(stderr, "%s", err2); @@ -3144,7 +3144,7 @@ static int getDimensionSizes(struct Input *in, FILE *strm) /* same as getDimensionSizes. But defined separately for extensibility */ static int getChunkedDimensionSizes(struct Input *in, FILE *strm) { - int ival; + unsigned long long ullval; int i = 0; const char *err1 = "Unable to allocate dynamic memory.\n"; @@ -3156,8 +3156,8 @@ static int getChunkedDimensionSizes(struct Input *in, FILE *strm) return (-1); } - while (fscanf(strm, "%d", (&ival)) == 1) - in->sizeOfChunk[i++] = ival; + while (fscanf(strm, "%llu", (&ullval)) == 1) + in->sizeOfChunk[i++] = ullval; if (in->rank != i) { (void) HDfprintf(stderr, "%s", err2); @@ -3174,7 +3174,7 @@ static int getChunkedDimensionSizes(struct Input *in, FILE *strm) static int getMaximumDimensionSizes(struct Input *in, FILE *strm) { - int ival; + long long llval; int i = 0; const char *err1 = "Unable to allocate dynamic memory.\n"; @@ -3186,11 +3186,11 @@ static int getMaximumDimensionSizes(struct Input *in, FILE *strm) return (-1); } - while (fscanf(strm, "%d", (&ival)) == 1) { - if (ival == -1) + while (fscanf(strm, "%lld", (&llval)) == 1) { + if (llval == -1) in->maxsizeOfDimension[i++] = H5S_UNLIMITED; else - in->maxsizeOfDimension[i++] = ival; + in->maxsizeOfDimension[i++] = (hsize_t)llval; } if (in->rank != i) { @@ -3927,7 +3927,7 @@ static int process(struct Options *opt) return (-1); } HDfclose(extfile); - H5Pset_external(proplist, in->externFilename, (off_t) 0, numOfElements * in->inputSize / 8); + H5Pset_external(proplist, in->externFilename, (off_t)0, numOfElements * (hsize_t)in->inputSize / 8); } /* create dataspace */ |