From de04c00ceb8d86855f9a773a024d401a71f76074 Mon Sep 17 00:00:00 2001 From: David A Minton Date: Thu, 14 Oct 2021 10:15:30 -0400 Subject: [PATCH] Fixed issue that was causing the param file reading to fail when reading in a netcdf input file --- src/io/io.f90 | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/io/io.f90 b/src/io/io.f90 index e206c40cf..e00310a1b 100644 --- a/src/io/io.f90 +++ b/src/io/io.f90 @@ -735,7 +735,7 @@ module subroutine io_param_reader(self, unit, iotype, v_list, iostat, iomsg) iostat = -1 return end if - if ((param%in_type /= REAL8_TYPE) .and. (param%in_type /= "ASCII")) then + if ((param%in_type /= REAL8_TYPE) .and. (param%in_type /= "ASCII") .and. (param%in_type /= NETCDF_FLOAT_TYPE) .and. (param%in_type /= NETCDF_DOUBLE_TYPE)) then write(iomsg,*) 'Invalid input file type:',trim(adjustl(param%in_type)) iostat = -1 return @@ -948,7 +948,9 @@ module subroutine io_param_writer(self, unit, iotype, v_list, iostat, iomsg) call io_param_writer_one("OUT_FORM", param%out_form, unit) call io_param_writer_one("OUT_STAT", "APPEND", unit) end if - call io_param_writer_one("PARTICLE_OUT", param%particle_out, unit) + if ((param%out_type /= REAL4_TYPE) .and. (param%out_type /= REAL8_TYPE)) then + call io_param_writer_one("PARTICLE_OUT", param%particle_out, unit) + end if if (param%enc_out /= "") then call io_param_writer_one("ENC_OUT", param%enc_out, unit) end if