Skip to content

Commit

Permalink
Small fixes to allow use-mpi-no and multi-metal field runs.
Browse files Browse the repository at this point in the history
--HG--
branch : week-of-code
  • Loading branch information
John Wise committed May 13, 2010
1 parent 6bc4fe4 commit bac346e
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/enzo/Grid_SolveCoupledRateEquations.C
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ int grid::SolveCoupledRateEquations()
float *MetalPointer;
float *TotalMetals = NULL;

if (MetalNum != -1 && SNColour != -1) {
if (MetalNum != -1 && SNColourNum != -1) {
for (dim = 0, size = 1; dim < GridRank; dim++)
size *= GridDimension[dim];
TotalMetals = new float[size];
Expand Down
2 changes: 1 addition & 1 deletion src/enzo/Grid_SolveRateAndCoolEquations.C
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ int grid::SolveRateAndCoolEquations()
float *MetalPointer;
float *TotalMetals = NULL;

if (MetalNum != -1 && SNColour != -1) {
if (MetalNum != -1 && SNColourNum != -1) {
TotalMetals = new float[size];
for (i = 0; i < size; i++)
TotalMetals[i] = BaryonField[MetalNum][i] + BaryonField[SNColourNum][i];
Expand Down
4 changes: 2 additions & 2 deletions src/enzo/PhotonCommunication.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@
#define EXTERN extern
#endif /* DEFINE_STORAGE */

#ifdef USE_MPI

#define MAX_PH_RECEIVE_BUFFERS 50000
#define MAX_PH_REQUESTS 50000

Expand All @@ -22,6 +20,8 @@
#define BUFFER_END -99999
#define NO_HINT -1

#ifdef USE_MPI

EXTERN char *PH_CommunicationReceiveBuffer[MAX_PH_RECEIVE_BUFFERS];
EXTERN MPI_Request PH_CommunicationReceiveMPI_Request[MAX_PH_RECEIVE_BUFFERS];
EXTERN Eint32 PH_CommunicationReceiveIndex;
Expand Down

0 comments on commit bac346e

Please sign in to comment.