diff options
author | jthorn <jthorn@f88db872-0e4f-0410-b76b-b9085cfa78c5> | 2003-05-14 11:34:19 +0000 |
---|---|---|
committer | jthorn <jthorn@f88db872-0e4f-0410-b76b-b9085cfa78c5> | 2003-05-14 11:34:19 +0000 |
commit | 61a425b274a27464a41a76297054aedf7870f4d9 (patch) | |
tree | e1c5676bdf7357130e7cf56b895cd1f90d471b56 /src/gr | |
parent | 6d4db36bf583dba44806b8662f17e9ab20938e3a (diff) |
fix error-handling code for when one processor gets CCTK_INTERP_ERROR_POINT_OUTSIDE
git-svn-id: http://svn.einsteintoolkit.org/cactus/EinsteinAnalysis/AHFinderDirect/trunk@1058 f88db872-0e4f-0410-b76b-b9085cfa78c5
Diffstat (limited to 'src/gr')
-rw-r--r-- | src/gr/expansion.cc | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/gr/expansion.cc b/src/gr/expansion.cc index c030942..6e603b6 100644 --- a/src/gr/expansion.cc +++ b/src/gr/expansion.cc @@ -653,11 +653,15 @@ if (status == CCTK_ERROR_INTERP_POINT_OUTSIDE) // to see if the local interpolator reported an error on this // processor, and if so, *which* point is out-of-range CCTK_INT local_interpolator_status; - CCTK_INT error_pt, error_axis, error_direction; const int status_interp = Util_TableGetInt(gi.param_table_handle, &local_interpolator_status, "local_interpolator_status"); + const bool point_outside_on_this_processor + = (status_interp > 0) + && (local_interpolator_status == CCTK_ERROR_INTERP_POINT_OUTSIDE); + + CCTK_INT error_pt, error_axis, error_direction; const int status_pt = Util_TableGetInt(gi.param_table_handle, &error_pt, "error_pt"); @@ -667,9 +671,9 @@ if (status == CCTK_ERROR_INTERP_POINT_OUTSIDE) const int status_direction = Util_TableGetInt(gi.param_table_handle, &error_direction, "error_direction"); - if ( (status_interp > 0) && (status_pt > 0) - && (status_axis > 0) - && (status_direction > 0) ) + if (point_outside_on_this_processor && (status_pt > 0) + && (status_axis > 0) + && (status_direction > 0)) then { assert(error_pt >= 0); assert(error_pt < ps_ptr->N_grid_points()); |