mirror of
https://github.com/HDFGroup/hdf5.git
synced 2024-11-27 02:10:55 +08:00
[svn-r2875] Purpose:
Code cleanup Description: Eliminated some warnings on O2K platform. Platforms tested: SGI O2K (modi4)
This commit is contained in:
parent
8ea1fc564f
commit
6c603f3e77
@ -416,7 +416,6 @@ H5O_dtype_decode_helper(H5F_t *f, const uint8_t **pp, H5T_t *dt)
|
||||
default:
|
||||
HRETURN_ERROR(H5E_DATATYPE, H5E_UNSUPPORTED, FAIL,
|
||||
"unknown datatype class found");
|
||||
break;
|
||||
}
|
||||
|
||||
FUNC_LEAVE(SUCCEED);
|
||||
|
@ -378,7 +378,7 @@ h5_fileaccess(void)
|
||||
if ((val = strtok(NULL, " \t\n\r")))
|
||||
verbosity = strtol(val, NULL, 0);
|
||||
|
||||
if (H5Pset_fapl_log(fapl, NULL, verbosity) < 0)
|
||||
if (H5Pset_fapl_log(fapl, NULL, (int)verbosity) < 0)
|
||||
return -1;
|
||||
} else {
|
||||
/* Unknown driver */
|
||||
|
@ -247,7 +247,7 @@ h5dump_str_append(h5dump_str_t *str/*in,out*/, const char *fmt, ...)
|
||||
|
||||
while (1) {
|
||||
size_t avail = str->nalloc - str->len;
|
||||
size_t nchars = HDvsnprintf(str->s+str->len, avail, fmt, ap);
|
||||
size_t nchars = (size_t)HDvsnprintf(str->s+str->len, avail, fmt, ap);
|
||||
|
||||
if (nchars < avail) {
|
||||
/* success */
|
||||
@ -1533,8 +1533,8 @@ h5dump_simple_dset(FILE *stream, const h5dump_t *info, hid_t dset,
|
||||
return -1;
|
||||
|
||||
/* Print the data */
|
||||
flags = ((elmtno == 0 ? START_OF_DATA : 0) |
|
||||
((elmtno + hs_nelmts) >= p_nelmts ? END_OF_DATA : 0));
|
||||
flags = (((elmtno == 0) ? START_OF_DATA : 0) |
|
||||
(((elmtno + hs_nelmts) >= p_nelmts) ? END_OF_DATA : 0));
|
||||
h5dump_simple_data(stream, info, dset, &ctx, flags, hs_nelmts,
|
||||
p_type, sm_buf);
|
||||
|
||||
|
@ -126,21 +126,21 @@ int main(void)
|
||||
|| fnok[0] != fptr[2] || fnok[1] != fptr[3]) {
|
||||
result = 1;
|
||||
printf("%14s (%2d) %6s = %s\n",
|
||||
mname = H5Tget_member_name(fix, 0), H5Tget_member_offset(fix,0),
|
||||
mname = H5Tget_member_name(fix, 0), (int)H5Tget_member_offset(fix,0),
|
||||
string5, (char *)(data + H5Tget_member_offset(fix, 0)));
|
||||
free(mname);
|
||||
fptr = (float *)(data + H5Tget_member_offset(fix, 1));
|
||||
printf("Data comparison:\n"
|
||||
"%14s (%2d) %6f = %f\n"
|
||||
" %6f = %f\n",
|
||||
mname = H5Tget_member_name(fix, 1), H5Tget_member_offset(fix,1),
|
||||
mname = H5Tget_member_name(fix, 1), (int)H5Tget_member_offset(fix,1),
|
||||
fok[0], fptr[0],
|
||||
fok[1], fptr[1]);
|
||||
free(mname);
|
||||
fptr = (float *)(data + H5Tget_member_offset(fix, 2));
|
||||
printf("%14s (%2d) %6f = %f\n"
|
||||
" %6f = %6f\n",
|
||||
mname = H5Tget_member_name(fix, 2), H5Tget_member_offset(fix,2),
|
||||
mname = H5Tget_member_name(fix, 2), (int)H5Tget_member_offset(fix,2),
|
||||
fnok[0], fptr[0],
|
||||
fnok[1], fptr[1]);
|
||||
free(mname);
|
||||
|
Loading…
Reference in New Issue
Block a user