Ignore:
Timestamp:
Sep 13, 2018 3:14:50 PM (6 years ago)
Author:
sward
Message:

Added error handling for wrong input parameters

File:
1 edited

Legend:

Unmodified
Added
Removed
  • palm/trunk/SOURCE/uv_exposure_model_mod.f90

    r3241 r3246  
    2525! -----------------
    2626! $Id$
     27! Added error handling for input namelist via parin_fail_message and small
     28! typo bugfix
     29!
     30! 3241 2018-09-12 15:02:00Z raasch
    2731! unused variables removed
    2832!
     
    449453    REWIND ( 11 )
    450454    line = ' '
    451     DO   WHILE ( INDEX( line, '&biometerology_parameters' ) == 0 )
    452        READ ( 11, '(A)', END=10 )  line
     455    DO   WHILE ( INDEX( line, '&biometeorology_parameters' ) == 0 )
     456       READ ( 11, '(A)', END=20 )  line
    453457    ENDDO
    454458    BACKSPACE ( 11 )
     
    456460!
    457461!-- Read user-defined namelist
    458     READ ( 11, biometeorology_parameters )
     462    READ ( 11, biometeorology_parameters, ERR = 10, END = 20 )
    459463
    460464!
     
    462466    uv_exposure = .TRUE.
    463467
    464 
    465  10 CONTINUE
     468 10 BACKSPACE( 11 )
     469    READ( 11 ,fmt='(A)') line
     470    CALL parin_fail_message ( 'biometeorology_parameters', line )
     471
     472
     473 20 CONTINUE
    466474       
    467475
Note: See TracChangeset for help on using the changeset viewer.