two errors in npzd_iron_inp.h

Bug reports, work arounds and fixes

Moderators: arango, robertson

Post Reply
Message
Author
jpm
Posts: 21
Joined: Thu Aug 27, 2009 4:37 pm
Location: UCSC

two errors in npzd_iron_inp.h

#1 Unread post by jpm »

In ROMS:

The current version (ROMS 696) of npzd_iron_inp.h contains 2 errors that cause a segmentation fault and a compilation failure, respectively.

In line 209 and line 219: There is a missing input argument in function call to load_lbc (this causes a segmentation fault while reading in the biological boundary conditions):

line 209:

Code: Select all

              Npts=load_lbc(Nval, Cval, line, nline, ifield, igrid,     &
     &                      iTrcStr, iTrcEnd, LBC)
fix:

Code: Select all

              Npts=load_lbc(Nval, Cval, line, nline, ifield, igrid,     &
     &                      iTrcStr, iTrcEnd,                           &
     &                      Vname(1,idTvar(idbio(itracer))), LBC)
The same issue is present in line 219:

Code: Select all

              Npts=load_lbc(Nval, Cval, line, nline, ifield, igrid,     &
     &                      iTrcStr, iTrcEnd, ad_LBC)
In line 644: "END SELECT" instead of "END IF"; this one is pretty obvious:

Code: Select all

!
!-----------------------------------------------------------------------
!  Report input parameters.
!-----------------------------------------------------------------------
!
      IF (Lwrite) THEN
        DO ng=1,Ngrids
          IF (Lbiology(ng)) THEN
        ...
          END SELECT

        END DO
      END IF
END SELECT in npzd_iron_inp.h
Jann Paul Mattern, Ocean Sciences Department, UCSC

User avatar
arango
Site Admin
Posts: 1349
Joined: Wed Feb 26, 2003 4:41 pm
Location: DMCS, Rutgers University
Contact:

Re: two errors in npzd_iron_inp.h

#2 Unread post by arango »

The load_lbc arguments in the current version of npzd_iron_inp.h in the repository were correct. Perhaps, you are using an older version of this routine. However, I have to correct the END SELECT statement to END IF. Thank you for bringing this to my attention.

jpm
Posts: 21
Joined: Thu Aug 27, 2009 4:37 pm
Location: UCSC

Re: two errors in npzd_iron_inp.h

#3 Unread post by jpm »

Great! In ROMS 696, I noticed the first bug was still present but having just updated to the latest version 697 I can confirm it is fixed. Thanks
Jann Paul Mattern, Ocean Sciences Department, UCSC

Post Reply