aboutsummaryrefslogtreecommitdiff
path: root/Carpet/CarpetSlab/src
diff options
context:
space:
mode:
authorErik Schnetter <schnetter@cct.lsu.edu>2007-03-08 00:50:00 +0000
committerErik Schnetter <schnetter@cct.lsu.edu>2007-03-08 00:50:00 +0000
commit63e022c921a578847f587b58c2a855ad2f261811 (patch)
treed95e347a64ec2164d58870927326bafc7fe70202 /Carpet/CarpetSlab/src
parent5d5fc1bb427ffee2486b1ca93124db7f0f0c1c5c (diff)
CarpetSlab: Use numeric_limits<int>::max() instead of INT_MAX
darcs-hash:20070308005038-dae7b-0188a2df680cbf144eab0400d8f3bc81df5ab2e2.gz
Diffstat (limited to 'Carpet/CarpetSlab/src')
-rw-r--r--Carpet/CarpetSlab/src/slab.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/Carpet/CarpetSlab/src/slab.cc b/Carpet/CarpetSlab/src/slab.cc
index 42fba1403..7bb364033 100644
--- a/Carpet/CarpetSlab/src/slab.cc
+++ b/Carpet/CarpetSlab/src/slab.cc
@@ -3,6 +3,7 @@
#include <string.h>
#include <algorithm>
+#include <limits>
#include <vector>
#include "cctk.h"
@@ -152,7 +153,7 @@ namespace CarpetSlab {
// Sanity check
// (if this fails, someone requested an insane number of grid points)
{
- int max = INT_MAX;
+ int max = numeric_limits<int>::max();
for (int dd=0; dd<hdim; ++dd) {
assert (length[dd] >= 0 && length[dd] <= max);
if (length[dd] > 0) max /= length[dd];