From 46caf9e7f7d1d73b91c4d38207d0288ccb705696 Mon Sep 17 00:00:00 2001 From: David A Minton Date: Thu, 5 Aug 2021 12:20:09 -0400 Subject: [PATCH] Fixed order in which radius is read in --- src/io/io.f90 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/io/io.f90 b/src/io/io.f90 index 612e16ec0..a7d278b2b 100644 --- a/src/io/io.f90 +++ b/src/io/io.f90 @@ -794,6 +794,7 @@ module subroutine io_read_body_in(self, param) end if self%Gmass(i) = real(val, kind=DP) self%mass(i) = real(val / param%GU, kind=DP) + if (param%lclose) read(iu, *, iostat=ierr, err=100) self%radius(i) class is (swiftest_tp) read(iu, *, iostat=ierr, err=100) self%id(i) end select @@ -801,7 +802,6 @@ module subroutine io_read_body_in(self, param) read(iu, *, iostat=ierr, err=100) self%vh(1, i), self%vh(2, i), self%vh(3, i) select type (self) class is (swiftest_pl) - if (param%lclose) read(iu, *, iostat=ierr, err=100) self%radius(i) if (param%lrotation) then read(iu, iostat=ierr, err=100) self%Ip(:, i) read(iu, iostat=ierr, err=100) self%rot(:, i)