aboutsummaryrefslogtreecommitdiff
path: root/Source
diff options
context:
space:
mode:
Diffstat (limited to 'Source')
-rw-r--r--Source/Diagnostics/BoostedFrameDiagnostic.cpp2
-rw-r--r--Source/Utils/WarpXUtil.cpp3
2 files changed, 2 insertions, 3 deletions
diff --git a/Source/Diagnostics/BoostedFrameDiagnostic.cpp b/Source/Diagnostics/BoostedFrameDiagnostic.cpp
index b7c771ce1..5be2c78fb 100644
--- a/Source/Diagnostics/BoostedFrameDiagnostic.cpp
+++ b/Source/Diagnostics/BoostedFrameDiagnostic.cpp
@@ -937,7 +937,7 @@ LabSnapShot(Real t_lab_in, Real t_boost, RealBox prob_domain_lab,
{
if (WarpX::do_boosted_frame_fields)
{
- for (int comp = 0; comp ncomp_to_dump; ++comp) {
+ for (int comp = 0; comp < ncomp_to_dump; ++comp) {
output_create_field(file_name, mesh_field_names_[comp],
prob_ncells_lab_[0],
#if ( AMREX_SPACEDIM == 3 )
diff --git a/Source/Utils/WarpXUtil.cpp b/Source/Utils/WarpXUtil.cpp
index 4ec7ebb51..a5ea6d75a 100644
--- a/Source/Utils/WarpXUtil.cpp
+++ b/Source/Utils/WarpXUtil.cpp
@@ -118,8 +118,7 @@ void NullifyMF(amrex::MultiFab& mf, int lev, amrex::Real zmin, amrex::Real zmax)
const int lo_ind = bx.loVect()[1];
#endif
// Check if box intersect with [zmin, zmax]
- if ( (zmin>zmin_box && zmin<=zmax_box) ||
- (zmax>zmin_box && zmax<=zmax_box) ){
+ if ( (zmax>zmin_box && zmin<=zmax_box) ){
Array4<Real> arr = mf[mfi].array();
// Set field to 0 between zmin and zmax
ParallelFor(bx,