diff --git a/src/IO/Spherical_IO.F90 b/src/IO/Spherical_IO.F90 index 800860a6..5e71e128 100755 --- a/src/IO/Spherical_IO.F90 +++ b/src/IO/Spherical_IO.F90 @@ -1721,7 +1721,7 @@ Subroutine Parse_Inds(indices_inout, indmax, indcount) jmin = indices_inout(i)+1 ! Only expand the subrange if the values of jmin and jmax - ! are consistent. + ! are consistent and if they fall within the grid bounds. If ((jmin .ge. 1) .and. (jmax .ge. jmin)) Then Do j = jmin,jmax If (j .le. indmax) Then