160 |
|
|
161 |
|
#else // is_mpi |
162 |
|
|
163 |
– |
cout << "master" <<endl; |
163 |
|
/* code to find maximum tag value */ |
164 |
|
|
165 |
< |
int tagub, flag, MAXTAG; |
165 |
> |
int *tagub, flag, MAXTAG; |
166 |
|
MPI_Attr_get(MPI_COMM_WORLD, MPI_TAG_UB, &tagub, &flag); |
167 |
|
if (flag) { |
168 |
< |
MAXTAG = tagub; |
168 |
> |
MAXTAG = *tagub; |
169 |
|
} else { |
170 |
|
MAXTAG = 32767; |
171 |
|
} |
228 |
|
MPI_Recv(MPIatomTypeString, MINIBUFFERSIZE, MPI_CHAR, which_node, |
229 |
|
myPotato, MPI_COMM_WORLD, &istatus); |
230 |
|
|
231 |
< |
strncpy(atomTypeString, MPIatomTypeString, MINIBUFFERSIZE); |
231 |
> |
//strncpy(atomTypeString, MPIatomTypeString, MINIBUFFERSIZE); |
232 |
|
|
233 |
|
// Null terminate the atomTypeString just in case: |
234 |
|
|
235 |
< |
atomTypeString[strlen(atomTypeString) - 1] = '\0'; |
236 |
< |
|
235 |
> |
//atomTypeString[strlen(atomTypeString) - 1] = '\0'; |
236 |
> |
atomTypeString = MPIatomTypeString; |
237 |
> |
|
238 |
|
myPotato++; |
239 |
|
|
240 |
|
MPI_Recv(&isDirectional, 1, MPI_INT, which_node, |
660 |
|
|
661 |
|
MPI_Recv(MPIatomTypeString, MINIBUFFERSIZE, MPI_CHAR, which_node, |
662 |
|
myPotato, MPI_COMM_WORLD, &istatus); |
663 |
– |
|
664 |
– |
strncpy(atomTypeString, MPIatomTypeString, MINIBUFFERSIZE); |
663 |
|
|
664 |
< |
// Null terminate the atomTypeString just in case: |
665 |
< |
|
668 |
< |
atomTypeString[strlen(atomTypeString) - 1] = '\0'; |
669 |
< |
|
664 |
> |
atomTypeString = MPIatomTypeString; |
665 |
> |
|
666 |
|
myPotato++; |
667 |
|
|
668 |
|
MPI_Recv(&isDirectional, 1, MPI_INT, which_node, |