Skip to content

Commit

Permalink
fix else branch indexing in dust_emis()
Browse files Browse the repository at this point in the history
  • Loading branch information
mjs271 committed Nov 19, 2024
1 parent ed3a8d7 commit be231dd
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/mam4xx/aero_model_emissions.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -329,9 +329,11 @@ void dust_emis(
cflux[inum] = cflux[idx_dust] * dust_mass_to_num[ibin];
}
} else {
for (int i = 0; i < dust_nbin; ++i) {
cflux[dust_indices[i]] = 0.0;
cflux[i] = 0.0;
for (int ibin = 0; ibin < dust_nbin; ++ibin) {
const int idx_dust = dust_indices[ibin];
const int inum = dust_indices[ibin + dust_nbin];
cflux[idx_dust] = 0.0;
cflux[inum] = 0.0;
}
}
// // local version (unnecessary?) that's zero if less than the threshold
Expand Down

0 comments on commit be231dd

Please sign in to comment.