diff --git a/src/misc/solver_module.f90 b/src/misc/solver_module.f90 index 410116b2a..936914561 100644 --- a/src/misc/solver_module.f90 +++ b/src/misc/solver_module.f90 @@ -424,22 +424,25 @@ end function f ! returns the minimum of two real numbers real(DP) Function Minimum(x1,x2) real(DP) x1,x2,resultat + if (x1 < x2) then - resultat = x1 + resultat = x1 else - resultat = x2 + resultat = x2 endif + Minimum = resultat end function Minimum ! TRUE if x1*x2 negative - integer Function RootBracketed(x1,x2) + logical Function RootBracketed(x1,x2) real(DP) x1,x2 - integer resultat + logical resultat + if ((x1 > 0.and.x2 > 0).or.(x1 < 0.and.x2 < 0)) then - resultat = 0 + resultat = .false. else - resultat = 1 + resultat = .true. endif RootBracketed = resultat end function RootBracketed diff --git a/src/netcdf_io/netcdf_io_implementations.f90 b/src/netcdf_io/netcdf_io_implementations.f90 index 40c561183..831b17902 100644 --- a/src/netcdf_io/netcdf_io_implementations.f90 +++ b/src/netcdf_io/netcdf_io_implementations.f90 @@ -40,8 +40,12 @@ module subroutine netcdf_io_close(self) character(namelen) :: message if (self%lfile_is_open) then +#ifdef COARRAY write(message,*) this_image() message = "netcdf_io_close on image " // trim(adjustl(message)) +#else + message = "netcdf_io_close" +#endif call netcdf_io_check( nf90_close(self%id), message) self%lfile_is_open = .false. end if diff --git a/src/swiftest/swiftest_driver.f90 b/src/swiftest/swiftest_driver.f90 index d8e2ae219..6cec24feb 100644 --- a/src/swiftest/swiftest_driver.f90 +++ b/src/swiftest/swiftest_driver.f90 @@ -33,7 +33,9 @@ program swiftest_driver param%integrator = trim(adjustl(integrator)) param%display_style = trim(adjustl(display_style)) call param%read_in(param_file_name) +#ifdef COARRAY if (.not.param%lcoarray .and. (this_image() /= 1)) stop ! Single image mode +#endif associate(t0 => param%t0, & tstart => param%tstart, &