1
1

coll_basic_barrier: guard against opal_hibit() returning -1

This was CID 1196606 and 1196607
Этот коммит содержится в:
Jeff Squyres 2015-02-24 06:45:04 -05:00
родитель 6c3ddf98ae
Коммит 1cf197d771
2 изменённых файлов: 8 добавлений и 0 удалений

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

@ -10,6 +10,7 @@
* Copyright (c) 2004-2005 The Regents of the University of California.
* All rights reserved.
* Copyright (c) 2012 Oak Ridge National Labs. All rights reserved.
* Copyright (c) 2015 Cisco Systems, Inc. All rights reserved.
* $COPYRIGHT$
*
* Additional copyrights may follow
@ -120,6 +121,9 @@ mca_coll_basic_barrier_intra_log(struct ompi_communicator_t *comm,
dim = comm->c_cube_dim;
hibit = opal_hibit(rank, dim);
if (hibit < 0) {
return MPI_ERR_OTHER;
}
--dim;
/* Receive from children. */

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

@ -9,6 +9,7 @@
* University of Stuttgart. All rights reserved.
* Copyright (c) 2004-2005 The Regents of the University of California.
* All rights reserved.
* Copyright (c) 2015 Cisco Systems, Inc. All rights reserved.
* $COPYRIGHT$
*
* Additional copyrights may follow
@ -134,6 +135,9 @@ mca_coll_basic_bcast_log_intra(void *buff, int count,
dim = comm->c_cube_dim;
hibit = opal_hibit(vrank, dim);
if (hibit < 0) {
return MPI_ERR_OTHER;
}
--dim;
/* Receive data from parent in the tree. */