aboutsummaryrefslogtreecommitdiff
path: root/Carpet/CarpetReduce/src/mask_coords.c
diff options
context:
space:
mode:
Diffstat (limited to 'Carpet/CarpetReduce/src/mask_coords.c')
-rw-r--r--Carpet/CarpetReduce/src/mask_coords.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/Carpet/CarpetReduce/src/mask_coords.c b/Carpet/CarpetReduce/src/mask_coords.c
index b945f6e1c..7836d2aa8 100644
--- a/Carpet/CarpetReduce/src/mask_coords.c
+++ b/Carpet/CarpetReduce/src/mask_coords.c
@@ -134,8 +134,12 @@ CoordBase_SetupMask (CCTK_ARGUMENTS)
directly on the boundary the weight 1/2 */
if (! is_staggered[2*d+f]) {
+ /* Since we are going to cut off 1/2 at each boundary, the
+ domain size must be at least 1 to begin with */
+ assert (int_points[d] >= 1);
+
/* Check whether the domain is empty */
- if (int_points[d] == 0) {
+ if (int_points[d] == 1) {
/* The domain is empty. The correct thing to do would be
to set the weights to 0. But this is boring, because