Skip to content

Commit

Permalink
Merge pull request #2651 from KaiSzuttor/lb_interface
Browse files Browse the repository at this point in the history
LB: fix build if LB_BOUNDARIES not compiled in.
  • Loading branch information
KaiSzuttor authored Apr 4, 2019
2 parents 3283344 + f9ea8f8 commit c80cf9e
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/core/grid_based_algorithms/lb_interface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -112,11 +112,13 @@ void mpi_bcast_lb_params(LBParam field) {
}

void mpi_recv_fluid_boundary_flag_slave(int node, int index) {
#ifdef LB_BOUNDARIES
if (node == this_node) {
int data;
lb_local_fields_get_boundary_flag(index, &data);
MPI_Send(&data, 1, MPI_INT, 0, SOME_TAG, comm_cart);
}
#endif
}

REGISTER_CALLBACK(mpi_recv_fluid_boundary_flag_slave)
Expand All @@ -128,6 +130,7 @@ REGISTER_CALLBACK(mpi_recv_fluid_boundary_flag_slave)
* @param boundary local boundary flag
*/
void mpi_recv_fluid_boundary_flag(int node, int index, int *boundary) {
#ifdef LB_BOUNDARIES
if (node == this_node) {
lb_local_fields_get_boundary_flag(index, boundary);
} else {
Expand All @@ -136,6 +139,7 @@ void mpi_recv_fluid_boundary_flag(int node, int index, int *boundary) {
MPI_Recv(&data, 1, MPI_INT, node, SOME_TAG, comm_cart, MPI_STATUS_IGNORE);
*boundary = data;
}
#endif
}

void mpi_recv_fluid_populations_slave(int node, int index) {
Expand Down

0 comments on commit c80cf9e

Please sign in to comment.