1
1

mpi/tool: Fix an incorrect type cast.

This bug caused an invalid result value on `MPI_T_cvar_read`
on big-endian machines or for large (>=2Gi) cvar values.
Этот коммит содержится в:
KAWASHIMA Takahiro 2015-10-29 12:43:55 +09:00
родитель 2dcb2d711b
Коммит c09f9f05d3

Просмотреть файл

@ -56,7 +56,7 @@ int MPI_T_cvar_read (MPI_T_cvar_handle handle, void *buf)
((unsigned long long *) buf)[0] = value->ullval;
break;
case MCA_BASE_VAR_TYPE_SIZE_T:
((int *) buf)[0] = value->sizetval;
((size_t *) buf)[0] = value->sizetval;
break;
case MCA_BASE_VAR_TYPE_BOOL:
((int *) buf)[0] = value->boolval;